<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><link rel="stylesheet" type="text/css" href="style.css" /><script type="text/javascript" src="highlight.js"></script></head><body><pre><span class="hs-pragma">{-# LANGUAGE GADTs, BangPatterns, ScopedTypeVariables #-}</span><span>
</span><span id="line-2"></span><span>
</span><span id="line-3"></span><span class="hs-keyword">module</span><span> </span><span class="hs-identifier">GHC.Cmm.CommonBlockElim</span><span>
</span><span id="line-4"></span><span>  </span><span class="hs-special">(</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#elimCommonBlocks"><span class="hs-identifier">elimCommonBlocks</span></a></span><span>
</span><span id="line-5"></span><span>  </span><span class="hs-special">)</span><span>
</span><span id="line-6"></span><span class="hs-keyword">where</span><span>
</span><span id="line-7"></span><span>
</span><span id="line-8"></span><span>
</span><span id="line-9"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Prelude.html"><span class="hs-identifier">GHC.Prelude</span></a></span><span> </span><span class="hs-keyword">hiding</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.List.html#iterate"><span class="hs-identifier">iterate</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.Enum.html#succ"><span class="hs-identifier">succ</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.List.html#unzip"><span class="hs-identifier">unzip</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/GHC.List.html#zip"><span class="hs-identifier">zip</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-10"></span><span>
</span><span id="line-11"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html"><span class="hs-identifier">GHC.Cmm.BlockId</span></a></span><span>
</span><span id="line-12"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.html"><span class="hs-identifier">GHC.Cmm</span></a></span><span>
</span><span id="line-13"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.Utils.html"><span class="hs-identifier">GHC.Cmm.Utils</span></a></span><span>
</span><span id="line-14"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.Switch.html"><span class="hs-identifier">GHC.Cmm.Switch</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Switch.html#eqSwitchTargetWith"><span class="hs-identifier">eqSwitchTargetWith</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-15"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.ContFlowOpt.html"><span class="hs-identifier">GHC.Cmm.ContFlowOpt</span></a></span><span>
</span><span id="line-16"></span><span>
</span><span id="line-17"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html"><span class="hs-identifier">GHC.Cmm.Dataflow.Block</span></a></span><span>
</span><span id="line-18"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Graph.html"><span class="hs-identifier">GHC.Cmm.Dataflow.Graph</span></a></span><span>
</span><span id="line-19"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html"><span class="hs-identifier">GHC.Cmm.Dataflow.Label</span></a></span><span>
</span><span id="line-20"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Collections.html"><span class="hs-identifier">GHC.Cmm.Dataflow.Collections</span></a></span><span>
</span><span id="line-21"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Bits.html#"><span class="hs-identifier">Data.Bits</span></a></span><span>
</span><span id="line-22"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Maybe.html#"><span class="hs-identifier">Data.Maybe</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/Data.Maybe.html#mapMaybe"><span class="hs-identifier">mapMaybe</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-23"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="../../base/src/Data.List.html#"><span class="hs-identifier">Data.List</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">List</span></span><span>
</span><span id="line-24"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Word.html#"><span class="hs-identifier">Data.Word</span></a></span><span>
</span><span id="line-25"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="../../containers/src/Data.Map.html#"><span class="hs-identifier">Data.Map</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">M</span></span><span>
</span><span id="line-26"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html"><span class="hs-identifier">GHC.Utils.Outputable</span></a></span><span>
</span><span id="line-27"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><a href="GHC.Data.TrieMap.html"><span class="hs-identifier">GHC.Data.TrieMap</span></a></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">TM</span></span><span>
</span><span id="line-28"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Types.Unique.FM.html"><span class="hs-identifier">GHC.Types.Unique.FM</span></a></span><span>
</span><span id="line-29"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Types.Unique.html"><span class="hs-identifier">GHC.Types.Unique</span></a></span><span>
</span><span id="line-30"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Control.Arrow.html#"><span class="hs-identifier">Control.Arrow</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/Control.Arrow.html#first"><span class="hs-identifier">first</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="../../base/src/Control.Arrow.html#second"><span class="hs-identifier">second</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-31"></span><span>
</span><span id="line-32"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-33"></span><span class="hs-comment">-- Eliminate common blocks</span><span>
</span><span id="line-34"></span><span>
</span><span id="line-35"></span><span class="hs-comment">-- If two blocks are identical except for the label on the first node,</span><span>
</span><span id="line-36"></span><span class="hs-comment">-- then we can eliminate one of the blocks. To ensure that the semantics</span><span>
</span><span id="line-37"></span><span class="hs-comment">-- of the program are preserved, we have to rewrite each predecessor of the</span><span>
</span><span id="line-38"></span><span class="hs-comment">-- eliminated block to proceed with the block we keep.</span><span>
</span><span id="line-39"></span><span>
</span><span id="line-40"></span><span class="hs-comment">-- The algorithm iterates over the blocks in the graph,</span><span>
</span><span id="line-41"></span><span class="hs-comment">-- checking whether it has seen another block that is equal modulo labels.</span><span>
</span><span id="line-42"></span><span class="hs-comment">-- If so, then it adds an entry in a map indicating that the new block</span><span>
</span><span id="line-43"></span><span class="hs-comment">-- is made redundant by the old block.</span><span>
</span><span id="line-44"></span><span class="hs-comment">-- Otherwise, it is added to the useful blocks.</span><span>
</span><span id="line-45"></span><span>
</span><span id="line-46"></span><span class="hs-comment">-- To avoid comparing every block with every other block repeatedly, we group</span><span>
</span><span id="line-47"></span><span class="hs-comment">-- them by</span><span>
</span><span id="line-48"></span><span class="hs-comment">--   * a hash of the block, ignoring labels (explained below)</span><span>
</span><span id="line-49"></span><span class="hs-comment">--   * the list of outgoing labels</span><span>
</span><span id="line-50"></span><span class="hs-comment">-- The hash is invariant under relabeling, so we only ever compare within</span><span>
</span><span id="line-51"></span><span class="hs-comment">-- the same group of blocks.</span><span>
</span><span id="line-52"></span><span class="hs-comment">--</span><span>
</span><span id="line-53"></span><span class="hs-comment">-- The list of outgoing labels is updated as we merge blocks (that is why they</span><span>
</span><span id="line-54"></span><span class="hs-comment">-- are not included in the hash, which we want to calculate only once).</span><span>
</span><span id="line-55"></span><span class="hs-comment">--</span><span>
</span><span id="line-56"></span><span class="hs-comment">-- All in all, two blocks should never be compared if they have different</span><span>
</span><span id="line-57"></span><span class="hs-comment">-- hashes, and at most once otherwise. Previously, we were slower, and people</span><span>
</span><span id="line-58"></span><span class="hs-comment">-- rightfully complained: #10397</span><span>
</span><span id="line-59"></span><span>
</span><span id="line-60"></span><span class="hs-comment">-- TODO: Use optimization fuel</span><span>
</span><span id="line-61"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#elimCommonBlocks"><span class="hs-identifier hs-type">elimCommonBlocks</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmGraph"><span class="hs-identifier hs-type">CmmGraph</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmGraph"><span class="hs-identifier hs-type">CmmGraph</span></a></span><span>
</span><span id="line-62"></span><span id="elimCommonBlocks"><span class="annot"><span class="annottext">elimCommonBlocks :: CmmGraph -&gt; CmmGraph
</span><a href="GHC.Cmm.CommonBlockElim.html#elimCommonBlocks"><span class="hs-identifier hs-var hs-var">elimCommonBlocks</span></a></span></span><span> </span><span id="local-6989586621681048938"><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048938"><span class="hs-identifier hs-var">g</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; CmmGraph -&gt; CmmGraph
</span><a href="GHC.Cmm.ContFlowOpt.html#replaceLabels"><span class="hs-identifier hs-var">replaceLabels</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048936"><span class="hs-identifier hs-var">env</span></a></span><span> </span><span class="annot"><span class="annottext">(CmmGraph -&gt; CmmGraph) -&gt; CmmGraph -&gt; CmmGraph
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; CmmGraph -&gt; CmmGraph
</span><a href="GHC.Cmm.CommonBlockElim.html#copyTicks"><span class="hs-identifier hs-var">copyTicks</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048936"><span class="hs-identifier hs-var">env</span></a></span><span> </span><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048938"><span class="hs-identifier hs-var">g</span></a></span><span>
</span><span id="line-63"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-64"></span><span>     </span><span id="local-6989586621681048936"><span class="annot"><span class="annottext">env :: LabelMap BlockId
</span><a href="#local-6989586621681048936"><span class="hs-identifier hs-var hs-var">env</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; [[(Key, DistinctBlocks)]] -&gt; LabelMap BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#iterate"><span class="hs-identifier hs-var">iterate</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapEmpty"><span class="hs-identifier hs-var">mapEmpty</span></a></span><span> </span><span class="annot"><span class="annottext">[[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048932"><span class="hs-identifier hs-var">blocks_with_key</span></a></span><span>
</span><span id="line-65"></span><span>     </span><span class="hs-comment">-- The order of blocks doesn't matter here. While we could use</span><span>
</span><span id="line-66"></span><span>     </span><span class="hs-comment">-- revPostorder which drops unreachable blocks this is done in</span><span>
</span><span id="line-67"></span><span>     </span><span class="hs-comment">-- ContFlowOpt already which runs before this pass. So we use</span><span>
</span><span id="line-68"></span><span>     </span><span class="hs-comment">-- toBlockList since it is faster.</span><span>
</span><span id="line-69"></span><span>     </span><span id="local-6989586621681048931"><span class="annot"><span class="annottext">groups :: [DistinctBlocks]
</span><a href="#local-6989586621681048931"><span class="hs-identifier hs-var hs-var">groups</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmBlock -&gt; Int) -&gt; DistinctBlocks -&gt; [DistinctBlocks]
forall a. (a -&gt; Int) -&gt; [a] -&gt; [[a]]
</span><a href="GHC.Cmm.CommonBlockElim.html#groupByInt"><span class="hs-identifier hs-var">groupByInt</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; Int
</span><a href="GHC.Cmm.CommonBlockElim.html#hash_block"><span class="hs-identifier hs-var">hash_block</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmGraph -&gt; DistinctBlocks
</span><a href="GHC.Cmm.Utils.html#toBlockList"><span class="hs-identifier hs-var">toBlockList</span></a></span><span> </span><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048938"><span class="hs-identifier hs-var">g</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span class="hs-special">]</span><span class="hs-special">]</span><span>
</span><span id="line-70"></span><span>     </span><span id="local-6989586621681048932"><span class="annot"><span class="annottext">blocks_with_key :: [[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048932"><span class="hs-identifier hs-var hs-var">blocks_with_key</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span> </span><span class="hs-special">[</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmBlock -&gt; Key
forall (thing :: Extensibility -&gt; Extensibility -&gt; *)
       (e :: Extensibility).
NonLocal thing =&gt;
thing e C -&gt; Key
</span><a href="GHC.Cmm.Dataflow.Graph.html#successors"><span class="hs-identifier hs-var">successors</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048926"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048926"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621681048926"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048926"><span class="hs-identifier hs-var">b</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048925"><span class="hs-identifier hs-var">bs</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">|</span><span> </span><span id="local-6989586621681048925"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048925"><span class="hs-identifier hs-var">bs</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048931"><span class="hs-identifier hs-var">groups</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-71"></span><span>
</span><span id="line-72"></span><span class="hs-comment">-- Invariant: The blocks in the list are pairwise distinct</span><span>
</span><span id="line-73"></span><span class="hs-comment">-- (so avoid comparing them again)</span><span>
</span><span id="line-74"></span><span class="hs-keyword">type</span><span> </span><span id="DistinctBlocks"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-var">DistinctBlocks</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-75"></span><span class="hs-keyword">type</span><span> </span><span id="Key"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-var">Key</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html#Label"><span class="hs-identifier hs-type">Label</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-76"></span><span class="hs-keyword">type</span><span> </span><span id="Subst"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-var">Subst</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html#LabelMap"><span class="hs-identifier hs-type">LabelMap</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span>
</span><span id="line-77"></span><span>
</span><span id="line-78"></span><span class="hs-comment">-- The outer list groups by hash. We retain this grouping throughout.</span><span>
</span><span id="line-79"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#iterate"><span class="hs-identifier hs-type">iterate</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-type">Subst</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-type">Subst</span></a></span><span>
</span><span id="line-80"></span><span id="iterate"><span class="annot"><span class="annottext">iterate :: LabelMap BlockId -&gt; [[(Key, DistinctBlocks)]] -&gt; LabelMap BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#iterate"><span class="hs-identifier hs-var hs-var">iterate</span></a></span></span><span> </span><span id="local-6989586621681048922"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048922"><span class="hs-identifier hs-var">subst</span></a></span></span><span> </span><span id="local-6989586621681048921"><span class="annot"><span class="annottext">[[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048921"><span class="hs-identifier hs-var">blocks</span></a></span></span><span>
</span><span id="line-81"></span><span>    </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; Bool
forall (map :: * -&gt; *) a. IsMap map =&gt; map a -&gt; Bool
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapNull"><span class="hs-identifier hs-var">mapNull</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048919"><span class="hs-identifier hs-var">new_substs</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048922"><span class="hs-identifier hs-var">subst</span></a></span><span>
</span><span id="line-82"></span><span>    </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; [[(Key, DistinctBlocks)]] -&gt; LabelMap BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#iterate"><span class="hs-identifier hs-var">iterate</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048918"><span class="hs-identifier hs-var">subst'</span></a></span><span> </span><span class="annot"><span class="annottext">[[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048917"><span class="hs-identifier hs-var">updated_blocks</span></a></span><span>
</span><span id="line-83"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-84"></span><span>    </span><span class="annot"><a href="#local-6989586621681048916"><span class="hs-identifier hs-type">grouped_blocks</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span class="hs-special">]</span><span class="hs-special">]</span><span>
</span><span id="line-85"></span><span>    </span><span id="local-6989586621681048916"><span class="annot"><span class="annottext">grouped_blocks :: [[(Key, [DistinctBlocks])]]
</span><a href="#local-6989586621681048916"><span class="hs-identifier hs-var hs-var">grouped_blocks</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">([(Key, DistinctBlocks)] -&gt; [(Key, [DistinctBlocks])])
-&gt; [[(Key, DistinctBlocks)]] -&gt; [[(Key, [DistinctBlocks])]]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">[(Key, DistinctBlocks)] -&gt; [(Key, [DistinctBlocks])]
</span><a href="GHC.Cmm.CommonBlockElim.html#groupByLabel"><span class="hs-identifier hs-var">groupByLabel</span></a></span><span> </span><span class="annot"><span class="annottext">[[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048921"><span class="hs-identifier hs-var">blocks</span></a></span><span>
</span><span id="line-86"></span><span>
</span><span id="line-87"></span><span>    </span><span class="annot"><a href="#local-6989586621681048914"><span class="hs-identifier hs-type">merged_blocks</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span class="hs-special">]</span><span>
</span><span id="line-88"></span><span>    </span><span class="hs-special">(</span><span id="local-6989586621681048919"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048919"><span class="hs-identifier hs-var">new_substs</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621681048914"><span class="annot"><span class="annottext">[[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048914"><span class="hs-identifier hs-var">merged_blocks</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(LabelMap BlockId
 -&gt; [(Key, [DistinctBlocks])]
 -&gt; (LabelMap BlockId, [(Key, DistinctBlocks)]))
-&gt; LabelMap BlockId
-&gt; [[(Key, [DistinctBlocks])]]
-&gt; (LabelMap BlockId, [[(Key, DistinctBlocks)]])
forall (t :: * -&gt; *) s a b.
Traversable t =&gt;
(s -&gt; a -&gt; (s, b)) -&gt; s -&gt; t a -&gt; (s, t b)
</span><a href="../../base/src/Data.Traversable.html#mapAccumL"><span class="hs-identifier hs-var">List.mapAccumL</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(LabelMap BlockId
 -&gt; (Key, [DistinctBlocks])
 -&gt; (LabelMap BlockId, (Key, DistinctBlocks)))
-&gt; LabelMap BlockId
-&gt; [(Key, [DistinctBlocks])]
-&gt; (LabelMap BlockId, [(Key, DistinctBlocks)])
forall (t :: * -&gt; *) s a b.
Traversable t =&gt;
(s -&gt; a -&gt; (s, b)) -&gt; s -&gt; t a -&gt; (s, t b)
</span><a href="../../base/src/Data.Traversable.html#mapAccumL"><span class="hs-identifier hs-var">List.mapAccumL</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
-&gt; (Key, [DistinctBlocks])
-&gt; (LabelMap BlockId, (Key, DistinctBlocks))
</span><a href="#local-6989586621681048912"><span class="hs-identifier hs-var">go</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapEmpty"><span class="hs-identifier hs-var">mapEmpty</span></a></span><span> </span><span class="annot"><span class="annottext">[[(Key, [DistinctBlocks])]]
</span><a href="#local-6989586621681048916"><span class="hs-identifier hs-var">grouped_blocks</span></a></span><span>
</span><span id="line-89"></span><span>      </span><span class="hs-keyword">where</span><span>
</span><span id="line-90"></span><span>        </span><span id="local-6989586621681048912"><span class="annot"><span class="annottext">go :: LabelMap BlockId
-&gt; (Key, [DistinctBlocks])
-&gt; (LabelMap BlockId, (Key, DistinctBlocks))
</span><a href="#local-6989586621681048912"><span class="hs-identifier hs-var hs-var">go</span></a></span></span><span> </span><span class="hs-glyph">!</span><span id="local-6989586621681048911"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048911"><span class="hs-identifier hs-var">new_subst1</span></a></span></span><span> </span><span class="hs-special">(</span><span id="local-6989586621681048910"><span class="annot"><span class="annottext">Key
</span><a href="#local-6989586621681048910"><span class="hs-identifier hs-var">k</span></a></span></span><span class="hs-special">,</span><span id="local-6989586621681048909"><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048909"><span class="hs-identifier hs-var">dbs</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048911"><span class="hs-identifier hs-var">new_subst1</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; LabelMap BlockId -&gt; LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a -&gt; map a -&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapUnion"><span class="hs-operator hs-var">`mapUnion`</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048907"><span class="hs-identifier hs-var">new_subst2</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Key
</span><a href="#local-6989586621681048910"><span class="hs-identifier hs-var">k</span></a></span><span class="hs-special">,</span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048906"><span class="hs-identifier hs-var">db</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-91"></span><span>          </span><span class="hs-keyword">where</span><span>
</span><span id="line-92"></span><span>            </span><span class="hs-special">(</span><span id="local-6989586621681048907"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048907"><span class="hs-identifier hs-var">new_subst2</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621681048906"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048906"><span class="hs-identifier hs-var">db</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
-&gt; [DistinctBlocks] -&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="GHC.Cmm.CommonBlockElim.html#mergeBlockList"><span class="hs-identifier hs-var">mergeBlockList</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048922"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048909"><span class="hs-identifier hs-var">dbs</span></a></span><span>
</span><span id="line-93"></span><span>
</span><span id="line-94"></span><span>    </span><span id="local-6989586621681048918"><span class="annot"><span class="annottext">subst' :: LabelMap BlockId
</span><a href="#local-6989586621681048918"><span class="hs-identifier hs-var hs-var">subst'</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048922"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; LabelMap BlockId -&gt; LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a -&gt; map a -&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapUnion"><span class="hs-operator hs-var">`mapUnion`</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048919"><span class="hs-identifier hs-var">new_substs</span></a></span><span>
</span><span id="line-95"></span><span>    </span><span id="local-6989586621681048917"><span class="annot"><span class="annottext">updated_blocks :: [[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048917"><span class="hs-identifier hs-var hs-var">updated_blocks</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">([(Key, DistinctBlocks)] -&gt; [(Key, DistinctBlocks)])
-&gt; [[(Key, DistinctBlocks)]] -&gt; [[(Key, DistinctBlocks)]]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">((Key, DistinctBlocks) -&gt; (Key, DistinctBlocks))
-&gt; [(Key, DistinctBlocks)] -&gt; [(Key, DistinctBlocks)]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(Key -&gt; Key) -&gt; (Key, DistinctBlocks) -&gt; (Key, DistinctBlocks)
forall (a :: * -&gt; * -&gt; *) b c d.
Arrow a =&gt;
a b c -&gt; a (b, d) (c, d)
</span><a href="../../base/src/Control.Arrow.html#first"><span class="hs-identifier hs-var">first</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId) -&gt; Key -&gt; Key
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; BlockId -&gt; BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#lookupBid"><span class="hs-identifier hs-var">lookupBid</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048918"><span class="hs-identifier hs-var">subst'</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[[(Key, DistinctBlocks)]]
</span><a href="#local-6989586621681048914"><span class="hs-identifier hs-var">merged_blocks</span></a></span><span>
</span><span id="line-96"></span><span>
</span><span id="line-97"></span><span class="hs-comment">-- Combine two lists of blocks.</span><span>
</span><span id="line-98"></span><span class="hs-comment">-- While they are internally distinct they can still share common blocks.</span><span>
</span><span id="line-99"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#mergeBlocks"><span class="hs-identifier hs-type">mergeBlocks</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-type">Subst</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-type">Subst</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-100"></span><span id="mergeBlocks"><span class="annot"><span class="annottext">mergeBlocks :: LabelMap BlockId
-&gt; DistinctBlocks
-&gt; DistinctBlocks
-&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="GHC.Cmm.CommonBlockElim.html#mergeBlocks"><span class="hs-identifier hs-var hs-var">mergeBlocks</span></a></span></span><span> </span><span id="local-6989586621681048902"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048902"><span class="hs-identifier hs-var">subst</span></a></span></span><span> </span><span id="local-6989586621681048901"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048901"><span class="hs-identifier hs-var">existing</span></a></span></span><span> </span><span id="local-6989586621681048900"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048900"><span class="hs-identifier hs-var">new</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">DistinctBlocks -&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048899"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048900"><span class="hs-identifier hs-var">new</span></a></span><span>
</span><span id="line-101"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-102"></span><span>    </span><span id="local-6989586621681048899"><span class="annot"><span class="annottext">go :: DistinctBlocks -&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048899"><span class="hs-identifier hs-var hs-var">go</span></a></span></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapEmpty"><span class="hs-identifier hs-var">mapEmpty</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048901"><span class="hs-identifier hs-var">existing</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-103"></span><span>    </span><span class="annot"><a href="#local-6989586621681048899"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="hs-special">(</span><span id="local-6989586621681048898"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048898"><span class="hs-identifier hs-var">b</span></a></span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621681048897"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048897"><span class="hs-identifier hs-var">bs</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">(CmmBlock -&gt; Bool) -&gt; DistinctBlocks -&gt; Maybe CmmBlock
forall (t :: * -&gt; *) a. Foldable t =&gt; (a -&gt; Bool) -&gt; t a -&gt; Maybe a
</span><a href="../../base/src/Data.Foldable.html#find"><span class="hs-identifier hs-var">List.find</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmBlock -&gt; CmmBlock -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqBlockBodyWith"><span class="hs-identifier hs-var">eqBlockBodyWith</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; BlockId -&gt; BlockId -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqBid"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048902"><span class="hs-identifier hs-var">subst</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048898"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048901"><span class="hs-identifier hs-var">existing</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-104"></span><span>        </span><span class="hs-comment">-- This block is a duplicate. Drop it, and add it to the substitution</span><span>
</span><span id="line-105"></span><span>        </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621681048893"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048893"><span class="hs-identifier hs-var">b'</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">(LabelMap BlockId -&gt; LabelMap BlockId)
-&gt; (LabelMap BlockId, DistinctBlocks)
-&gt; (LabelMap BlockId, DistinctBlocks)
forall (a :: * -&gt; * -&gt; *) b c d.
Arrow a =&gt;
a b c -&gt; a (b, d) (c, d)
</span><a href="../../base/src/Control.Arrow.html#first"><span class="hs-identifier hs-var">first</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">KeyOf LabelMap -&gt; BlockId -&gt; LabelMap BlockId -&gt; LabelMap BlockId
forall (map :: * -&gt; *) a.
IsMap map =&gt;
KeyOf map -&gt; a -&gt; map a -&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapInsert"><span class="hs-identifier hs-var">mapInsert</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmBlock -&gt; BlockId
forall (thing :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
NonLocal thing =&gt;
thing C x -&gt; BlockId
</span><a href="GHC.Cmm.Dataflow.Graph.html#entryLabel"><span class="hs-identifier hs-var">entryLabel</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048898"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmBlock -&gt; BlockId
forall (thing :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
NonLocal thing =&gt;
thing C x -&gt; BlockId
</span><a href="GHC.Cmm.Dataflow.Graph.html#entryLabel"><span class="hs-identifier hs-var">entryLabel</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048893"><span class="hs-identifier hs-var">b'</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">((LabelMap BlockId, DistinctBlocks)
 -&gt; (LabelMap BlockId, DistinctBlocks))
-&gt; (LabelMap BlockId, DistinctBlocks)
-&gt; (LabelMap BlockId, DistinctBlocks)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks -&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048899"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048897"><span class="hs-identifier hs-var">bs</span></a></span><span>
</span><span id="line-106"></span><span>        </span><span class="hs-comment">-- This block is not a duplicate, keep it.</span><span>
</span><span id="line-107"></span><span>        </span><span class="annot"><span class="annottext">Maybe CmmBlock
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">(DistinctBlocks -&gt; DistinctBlocks)
-&gt; (LabelMap BlockId, DistinctBlocks)
-&gt; (LabelMap BlockId, DistinctBlocks)
forall (a :: * -&gt; * -&gt; *) b c d.
Arrow a =&gt;
a b c -&gt; a (d, b) (d, c)
</span><a href="../../base/src/Control.Arrow.html#second"><span class="hs-identifier hs-var">second</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048898"><span class="hs-identifier hs-var">b</span></a></span><span class="annot"><span class="annottext">CmmBlock -&gt; DistinctBlocks -&gt; DistinctBlocks
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">((LabelMap BlockId, DistinctBlocks)
 -&gt; (LabelMap BlockId, DistinctBlocks))
-&gt; (LabelMap BlockId, DistinctBlocks)
-&gt; (LabelMap BlockId, DistinctBlocks)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks -&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048899"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048897"><span class="hs-identifier hs-var">bs</span></a></span><span>
</span><span id="line-108"></span><span>
</span><span id="line-109"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#mergeBlockList"><span class="hs-identifier hs-type">mergeBlockList</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-type">Subst</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Subst"><span class="hs-identifier hs-type">Subst</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-110"></span><span id="mergeBlockList"><span class="annot"><span class="annottext">mergeBlockList :: LabelMap BlockId
-&gt; [DistinctBlocks] -&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="GHC.Cmm.CommonBlockElim.html#mergeBlockList"><span class="hs-identifier hs-var hs-var">mergeBlockList</span></a></span></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc -&gt; (LabelMap BlockId, DistinctBlocks)
forall a. HasCallStack =&gt; String -&gt; SDoc -&gt; a
</span><a href="GHC.Utils.Outputable.html#pprPanic"><span class="hs-identifier hs-var">pprPanic</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;mergeBlockList&quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#empty"><span class="hs-identifier hs-var">empty</span></a></span><span>
</span><span id="line-111"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#mergeBlockList"><span class="hs-identifier hs-var">mergeBlockList</span></a></span><span> </span><span id="local-6989586621681048888"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048888"><span class="hs-identifier hs-var">subst</span></a></span></span><span> </span><span class="hs-special">(</span><span id="local-6989586621681048887"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048887"><span class="hs-identifier hs-var">b</span></a></span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621681048886"><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048886"><span class="hs-identifier hs-var">bs</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
-&gt; DistinctBlocks
-&gt; [DistinctBlocks]
-&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048885"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapEmpty"><span class="hs-identifier hs-var">mapEmpty</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048887"><span class="hs-identifier hs-var">b</span></a></span><span> </span><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048886"><span class="hs-identifier hs-var">bs</span></a></span><span>
</span><span id="line-112"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-113"></span><span>    </span><span id="local-6989586621681048885"><span class="annot"><span class="annottext">go :: LabelMap BlockId
-&gt; DistinctBlocks
-&gt; [DistinctBlocks]
-&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048885"><span class="hs-identifier hs-var hs-var">go</span></a></span></span><span> </span><span class="hs-glyph">!</span><span id="local-6989586621681048884"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048884"><span class="hs-identifier hs-var">new_subst1</span></a></span></span><span> </span><span id="local-6989586621681048883"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048883"><span class="hs-identifier hs-var">b</span></a></span></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048884"><span class="hs-identifier hs-var">new_subst1</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048883"><span class="hs-identifier hs-var">b</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-114"></span><span>    </span><span class="annot"><a href="#local-6989586621681048885"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="hs-glyph">!</span><span id="local-6989586621681048882"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048882"><span class="hs-identifier hs-var">new_subst1</span></a></span></span><span> </span><span id="local-6989586621681048881"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048881"><span class="hs-identifier hs-var">b1</span></a></span></span><span> </span><span class="hs-special">(</span><span id="local-6989586621681048880"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048880"><span class="hs-identifier hs-var">b2</span></a></span></span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span id="local-6989586621681048879"><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048879"><span class="hs-identifier hs-var">bs</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
-&gt; DistinctBlocks
-&gt; [DistinctBlocks]
-&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="#local-6989586621681048885"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048878"><span class="hs-identifier hs-var">new_subst</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048877"><span class="hs-identifier hs-var">b</span></a></span><span> </span><span class="annot"><span class="annottext">[DistinctBlocks]
</span><a href="#local-6989586621681048879"><span class="hs-identifier hs-var">bs</span></a></span><span>
</span><span id="line-115"></span><span>      </span><span class="hs-keyword">where</span><span>
</span><span id="line-116"></span><span>        </span><span class="hs-special">(</span><span id="local-6989586621681048876"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048876"><span class="hs-identifier hs-var">new_subst2</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621681048877"><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048877"><span class="hs-identifier hs-var">b</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span>  </span><span class="annot"><span class="annottext">LabelMap BlockId
-&gt; DistinctBlocks
-&gt; DistinctBlocks
-&gt; (LabelMap BlockId, DistinctBlocks)
</span><a href="GHC.Cmm.CommonBlockElim.html#mergeBlocks"><span class="hs-identifier hs-var">mergeBlocks</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048888"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048881"><span class="hs-identifier hs-var">b1</span></a></span><span> </span><span class="annot"><span class="annottext">DistinctBlocks
</span><a href="#local-6989586621681048880"><span class="hs-identifier hs-var">b2</span></a></span><span>
</span><span id="line-117"></span><span>        </span><span id="local-6989586621681048878"><span class="annot"><span class="annottext">new_subst :: LabelMap BlockId
</span><a href="#local-6989586621681048878"><span class="hs-identifier hs-var hs-var">new_subst</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048882"><span class="hs-identifier hs-var">new_subst1</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; LabelMap BlockId -&gt; LabelMap BlockId
forall (map :: * -&gt; *) a. IsMap map =&gt; map a -&gt; map a -&gt; map a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapUnion"><span class="hs-operator hs-var">`mapUnion`</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048876"><span class="hs-identifier hs-var">new_subst2</span></a></span><span>
</span><span id="line-118"></span><span>
</span><span id="line-119"></span><span>
</span><span id="line-120"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-121"></span><span class="hs-comment">-- Hashing and equality on blocks</span><span>
</span><span id="line-122"></span><span>
</span><span id="line-123"></span><span class="hs-comment">-- Below here is mostly boilerplate: hashing blocks ignoring labels,</span><span>
</span><span id="line-124"></span><span class="hs-comment">-- and comparing blocks modulo a label mapping.</span><span>
</span><span id="line-125"></span><span>
</span><span id="line-126"></span><span class="hs-comment">-- To speed up comparisons, we hash each basic block modulo jump labels.</span><span>
</span><span id="line-127"></span><span class="hs-comment">-- The hashing is a bit arbitrary (the numbers are completely arbitrary),</span><span>
</span><span id="line-128"></span><span class="hs-comment">-- but it should be fast and good enough.</span><span>
</span><span id="line-129"></span><span>
</span><span id="line-130"></span><span class="hs-comment">-- We want to get as many small buckets as possible, as comparing blocks is</span><span>
</span><span id="line-131"></span><span class="hs-comment">-- expensive. So include as much as possible in the hash. Ideally everything</span><span>
</span><span id="line-132"></span><span class="hs-comment">-- that is compared with (==) in eqBlockBodyWith.</span><span>
</span><span id="line-133"></span><span>
</span><span id="line-134"></span><span class="hs-keyword">type</span><span> </span><span id="HashCode"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#HashCode"><span class="hs-identifier hs-var">HashCode</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>
</span><span id="line-135"></span><span>
</span><span id="line-136"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#hash_block"><span class="hs-identifier hs-type">hash_block</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#HashCode"><span class="hs-identifier hs-type">HashCode</span></a></span><span>
</span><span id="line-137"></span><span id="hash_block"><span class="annot"><span class="annottext">hash_block :: CmmBlock -&gt; Int
</span><a href="GHC.Cmm.CommonBlockElim.html#hash_block"><span class="hs-identifier hs-var hs-var">hash_block</span></a></span></span><span> </span><span id="local-6989586621681048874"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048874"><span class="hs-identifier hs-var">block</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-138"></span><span>  </span><span class="annot"><span class="annottext">Word32 -&gt; Int
forall a b. (Integral a, Num b) =&gt; a -&gt; b
</span><a href="../../base/src/GHC.Real.html#fromIntegral"><span class="hs-identifier hs-var">fromIntegral</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(CmmNode C O -&gt; Word32 -&gt; Word32, CmmNode O O -&gt; Word32 -&gt; Word32,
 CmmNode O C -&gt; Word32 -&gt; Word32)
-&gt; forall (e :: Extensibility) (x :: Extensibility).
   Block CmmNode e x
   -&gt; IndexedCO x Word32 Word32 -&gt; IndexedCO e Word32 Word32
forall (n :: Extensibility -&gt; Extensibility -&gt; *) a b c.
(n C O -&gt; b -&gt; c, n O O -&gt; b -&gt; b, n O C -&gt; a -&gt; b)
-&gt; forall (e :: Extensibility) (x :: Extensibility).
   Block n e x -&gt; IndexedCO x a b -&gt; IndexedCO e c b
</span><a href="GHC.Cmm.Dataflow.Block.html#foldBlockNodesB3"><span class="hs-identifier hs-var">foldBlockNodesB3</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmNode C O -&gt; Word32 -&gt; Word32
forall {p} {p}. p -&gt; p -&gt; p
</span><a href="#local-6989586621681048872"><span class="hs-identifier hs-var">hash_fst</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">CmmNode O O -&gt; Word32 -&gt; Word32
forall {x :: Extensibility}. CmmNode O x -&gt; Word32 -&gt; Word32
</span><a href="#local-6989586621681048871"><span class="hs-identifier hs-var">hash_mid</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">CmmNode O C -&gt; Word32 -&gt; Word32
forall {x :: Extensibility}. CmmNode O x -&gt; Word32 -&gt; Word32
</span><a href="#local-6989586621681048870"><span class="hs-identifier hs-var">hash_lst</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048874"><span class="hs-identifier hs-var">block</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">0</span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Bits a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/Data.Bits.html#.%26."><span class="hs-operator hs-var">.&amp;.</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">0x7fffffff</span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-139"></span><span>  </span><span class="hs-comment">-- UniqFM doesn't like negative Ints</span><span>
</span><span id="line-140"></span><span>  </span><span class="hs-keyword">where</span><span> </span><span id="local-6989586621681048872"><span class="annot"><span class="annottext">hash_fst :: p -&gt; p -&gt; p
</span><a href="#local-6989586621681048872"><span class="hs-identifier hs-var hs-var">hash_fst</span></a></span></span><span> </span><span class="annot"><span class="annottext">p
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681048868"><span class="annot"><span class="annottext">p
</span><a href="#local-6989586621681048868"><span class="hs-identifier hs-var">h</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">p
</span><a href="#local-6989586621681048868"><span class="hs-identifier hs-var">h</span></a></span><span>
</span><span id="line-141"></span><span>        </span><span id="local-6989586621681048871"><span class="annot"><span class="annottext">hash_mid :: CmmNode O x -&gt; Word32 -&gt; Word32
</span><a href="#local-6989586621681048871"><span class="hs-identifier hs-var hs-var">hash_mid</span></a></span></span><span> </span><span id="local-6989586621681048865"><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048865"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span id="local-6989586621681048864"><span class="annot"><span class="annottext">Word32
</span><a href="#local-6989586621681048864"><span class="hs-identifier hs-var">h</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmNode O x -&gt; Word32
forall (x :: Extensibility). CmmNode O x -&gt; Word32
</span><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048865"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">Word32
</span><a href="#local-6989586621681048864"><span class="hs-identifier hs-var">h</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Int -&gt; Word32
forall a. Bits a =&gt; a -&gt; Int -&gt; a
</span><a href="../../base/src/Data.Bits.html#shiftL"><span class="hs-operator hs-var">`shiftL`</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">1</span></span><span>
</span><span id="line-142"></span><span>        </span><span id="local-6989586621681048870"><span class="annot"><span class="annottext">hash_lst :: CmmNode O x -&gt; Word32 -&gt; Word32
</span><a href="#local-6989586621681048870"><span class="hs-identifier hs-var hs-var">hash_lst</span></a></span></span><span> </span><span id="local-6989586621681048858"><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048858"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span id="local-6989586621681048857"><span class="annot"><span class="annottext">Word32
</span><a href="#local-6989586621681048857"><span class="hs-identifier hs-var">h</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmNode O x -&gt; Word32
forall (x :: Extensibility). CmmNode O x -&gt; Word32
</span><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048858"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">Word32
</span><a href="#local-6989586621681048857"><span class="hs-identifier hs-var">h</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Int -&gt; Word32
forall a. Bits a =&gt; a -&gt; Int -&gt; a
</span><a href="../../base/src/Data.Bits.html#shiftL"><span class="hs-operator hs-var">`shiftL`</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">1</span></span><span>
</span><span id="line-143"></span><span>
</span><span id="line-144"></span><span>        </span><span id="local-6989586621681049135"><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-type">hash_node</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmNode"><span class="hs-identifier hs-type">CmmNode</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681049135"><span class="hs-identifier hs-type">x</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span></span><span>
</span><span id="line-145"></span><span>        </span><span id="local-6989586621681048863"><span class="annot"><span class="annottext">hash_node :: forall (x :: Extensibility). CmmNode O x -&gt; Word32
</span><a href="#local-6989586621681048863"><span class="hs-identifier hs-var hs-var">hash_node</span></a></span></span><span> </span><span id="local-6989586621681048853"><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048853"><span class="hs-identifier hs-var">n</span></a></span></span><span> </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">CmmNode O x -&gt; Bool
forall (x :: Extensibility). CmmNode O x -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var">dont_care</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048853"><span class="hs-identifier hs-var">n</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">0</span></span><span> </span><span class="hs-comment">-- don't care</span><span>
</span><span id="line-146"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmAssign"><span class="hs-identifier hs-type">CmmAssign</span></a></span><span> </span><span id="local-6989586621681048847"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048847"><span class="hs-identifier hs-var">r</span></a></span></span><span> </span><span id="local-6989586621681048846"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048846"><span class="hs-identifier hs-var">e</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmReg -&gt; Word32
</span><a href="#local-6989586621681048845"><span class="hs-identifier hs-var">hash_reg</span></a></span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048847"><span class="hs-identifier hs-var">r</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048846"><span class="hs-identifier hs-var">e</span></a></span><span>
</span><span id="line-147"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmStore"><span class="hs-identifier hs-type">CmmStore</span></a></span><span> </span><span id="local-6989586621681048839"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048839"><span class="hs-identifier hs-var">e</span></a></span></span><span> </span><span id="local-6989586621681048838"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048838"><span class="hs-identifier hs-var">e'</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048839"><span class="hs-identifier hs-var">e</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048838"><span class="hs-identifier hs-var">e'</span></a></span><span>
</span><span id="line-148"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmUnsafeForeignCall"><span class="hs-identifier hs-type">CmmUnsafeForeignCall</span></a></span><span> </span><span id="local-6989586621681048832"><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048832"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span class="annot"><span class="annottext">[LocalReg]
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681048831"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048831"><span class="hs-keyword hs-var">as</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ForeignTarget -&gt; Word32
</span><a href="#local-6989586621681048830"><span class="hs-identifier hs-var">hash_tgt</span></a></span><span> </span><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048832"><span class="hs-identifier hs-var">t</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">(CmmExpr -&gt; Word32) -&gt; [CmmExpr] -&gt; Word32
forall {t :: * -&gt; *} {t}.
Foldable t =&gt;
(t -&gt; Word32) -&gt; t t -&gt; Word32
</span><a href="#local-6989586621681048829"><span class="hs-identifier hs-var">hash_list</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048831"><span class="hs-keyword hs-var">as</span></a></span><span>
</span><span id="line-149"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmBranch"><span class="hs-identifier hs-type">CmmBranch</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">23</span></span><span> </span><span class="hs-comment">-- NB. ignore the label</span><span>
</span><span id="line-150"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmCondBranch"><span class="hs-identifier hs-type">CmmCondBranch</span></a></span><span> </span><span id="local-6989586621681048821"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048821"><span class="hs-identifier hs-var">p</span></a></span></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Maybe Bool
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048821"><span class="hs-identifier hs-var">p</span></a></span><span>
</span><span id="line-151"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmCall"><span class="hs-identifier hs-type">CmmCall</span></a></span><span> </span><span id="local-6989586621681048817"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048817"><span class="hs-identifier hs-var">e</span></a></span></span><span> </span><span class="annot"><span class="annottext">Maybe BlockId
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">[GlobalReg]
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048817"><span class="hs-identifier hs-var">e</span></a></span><span>
</span><span id="line-152"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmForeignCall"><span class="hs-identifier hs-type">CmmForeignCall</span></a></span><span> </span><span id="local-6989586621681048813"><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048813"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span class="annot"><span class="annottext">[LocalReg]
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ForeignTarget -&gt; Word32
</span><a href="#local-6989586621681048830"><span class="hs-identifier hs-var">hash_tgt</span></a></span><span> </span><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048813"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-153"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmSwitch"><span class="hs-identifier hs-type">CmmSwitch</span></a></span><span> </span><span id="local-6989586621681048809"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048809"><span class="hs-identifier hs-var">e</span></a></span></span><span> </span><span class="annot"><span class="annottext">SwitchTargets
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048809"><span class="hs-identifier hs-var">e</span></a></span><span>
</span><span id="line-154"></span><span>        </span><span class="annot"><a href="#local-6989586621681048863"><span class="hs-identifier hs-var">hash_node</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O x
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Word32
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;hash_node: unknown Cmm node!&quot;</span></span><span>
</span><span id="line-155"></span><span>
</span><span id="line-156"></span><span>        </span><span class="annot"><a href="#local-6989586621681048845"><span class="hs-identifier hs-type">hash_reg</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmReg"><span class="hs-identifier hs-type">CmmReg</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span><span>
</span><span id="line-157"></span><span>        </span><span id="local-6989586621681048845"><span class="annot"><span class="annottext">hash_reg :: CmmReg -&gt; Word32
</span><a href="#local-6989586621681048845"><span class="hs-identifier hs-var hs-var">hash_reg</span></a></span></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLocal"><span class="hs-identifier hs-type">CmmLocal</span></a></span><span> </span><span id="local-6989586621681048806"><span class="annot"><span class="annottext">LocalReg
</span><a href="#local-6989586621681048806"><span class="hs-identifier hs-var">localReg</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LocalReg -&gt; Word32
forall a. Uniquable a =&gt; a -&gt; Word32
</span><a href="#local-6989586621681048805"><span class="hs-identifier hs-var">hash_unique</span></a></span><span> </span><span class="annot"><span class="annottext">LocalReg
</span><a href="#local-6989586621681048806"><span class="hs-identifier hs-var">localReg</span></a></span><span> </span><span class="hs-comment">-- important for performance, see #10397</span><span>
</span><span id="line-158"></span><span>        </span><span class="annot"><a href="#local-6989586621681048845"><span class="hs-identifier hs-var">hash_reg</span></a></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmGlobal"><span class="hs-identifier hs-type">CmmGlobal</span></a></span><span> </span><span class="annot"><span class="annottext">GlobalReg
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">19</span></span><span>
</span><span id="line-159"></span><span>
</span><span id="line-160"></span><span>        </span><span class="annot"><a href="#local-6989586621681048844"><span class="hs-identifier hs-type">hash_e</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmExpr"><span class="hs-identifier hs-type">CmmExpr</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span><span>
</span><span id="line-161"></span><span>        </span><span id="local-6989586621681048844"><span class="annot"><span class="annottext">hash_e :: CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var hs-var">hash_e</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLit"><span class="hs-identifier hs-type">CmmLit</span></a></span><span> </span><span id="local-6989586621681048802"><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048802"><span class="hs-identifier hs-var">l</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmLit -&gt; Word32
</span><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048802"><span class="hs-identifier hs-var">l</span></a></span><span>
</span><span id="line-162"></span><span>        </span><span class="annot"><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLoad"><span class="hs-identifier hs-type">CmmLoad</span></a></span><span> </span><span id="local-6989586621681048799"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048799"><span class="hs-identifier hs-var">e</span></a></span></span><span> </span><span class="annot"><span class="annottext">CmmType
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">67</span></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048799"><span class="hs-identifier hs-var">e</span></a></span><span>
</span><span id="line-163"></span><span>        </span><span class="annot"><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmReg"><span class="hs-identifier hs-type">CmmReg</span></a></span><span> </span><span id="local-6989586621681048797"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048797"><span class="hs-identifier hs-var">r</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmReg -&gt; Word32
</span><a href="#local-6989586621681048845"><span class="hs-identifier hs-var">hash_reg</span></a></span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048797"><span class="hs-identifier hs-var">r</span></a></span><span>
</span><span id="line-164"></span><span>        </span><span class="annot"><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmMachOp"><span class="hs-identifier hs-type">CmmMachOp</span></a></span><span> </span><span class="annot"><span class="annottext">MachOp
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681048795"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048795"><span class="hs-identifier hs-var">es</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmExpr -&gt; Word32) -&gt; [CmmExpr] -&gt; Word32
forall {t :: * -&gt; *} {t}.
Foldable t =&gt;
(t -&gt; Word32) -&gt; t t -&gt; Word32
</span><a href="#local-6989586621681048829"><span class="hs-identifier hs-var">hash_list</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048795"><span class="hs-identifier hs-var">es</span></a></span><span> </span><span class="hs-comment">-- pessimal - no operator check</span><span>
</span><span id="line-165"></span><span>        </span><span class="annot"><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmRegOff"><span class="hs-identifier hs-type">CmmRegOff</span></a></span><span> </span><span id="local-6989586621681048793"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048793"><span class="hs-identifier hs-var">r</span></a></span></span><span> </span><span id="local-6989586621681048792"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048792"><span class="hs-identifier hs-var">i</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmReg -&gt; Word32
</span><a href="#local-6989586621681048845"><span class="hs-identifier hs-var">hash_reg</span></a></span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048793"><span class="hs-identifier hs-var">r</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Word32
</span><a href="#local-6989586621681048791"><span class="hs-identifier hs-var">cvt</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048792"><span class="hs-identifier hs-var">i</span></a></span><span>
</span><span id="line-166"></span><span>        </span><span class="annot"><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmStackSlot"><span class="hs-identifier hs-type">CmmStackSlot</span></a></span><span> </span><span class="annot"><span class="annottext">Area
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">13</span></span><span>
</span><span id="line-167"></span><span>
</span><span id="line-168"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-type">hash_lit</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLit"><span class="hs-identifier hs-type">CmmLit</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span><span>
</span><span id="line-169"></span><span>        </span><span id="local-6989586621681048801"><span class="annot"><span class="annottext">hash_lit :: CmmLit -&gt; Word32
</span><a href="#local-6989586621681048801"><span class="hs-identifier hs-var hs-var">hash_lit</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmInt"><span class="hs-identifier hs-type">CmmInt</span></a></span><span> </span><span id="local-6989586621681048788"><span class="annot"><span class="annottext">Integer
</span><a href="#local-6989586621681048788"><span class="hs-identifier hs-var">i</span></a></span></span><span> </span><span class="annot"><span class="annottext">Width
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Integer -&gt; Word32
forall a. Num a =&gt; Integer -&gt; a
</span><a href="../../base/src/GHC.Num.html#fromInteger"><span class="hs-identifier hs-var">fromInteger</span></a></span><span> </span><span class="annot"><span class="annottext">Integer
</span><a href="#local-6989586621681048788"><span class="hs-identifier hs-var">i</span></a></span><span>
</span><span id="line-170"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmFloat"><span class="hs-identifier hs-type">CmmFloat</span></a></span><span> </span><span id="local-6989586621681048786"><span class="annot"><span class="annottext">Rational
</span><a href="#local-6989586621681048786"><span class="hs-identifier hs-var">r</span></a></span></span><span> </span><span class="annot"><span class="annottext">Width
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Rational -&gt; Word32
forall a b. (RealFrac a, Integral b) =&gt; a -&gt; b
</span><a href="../../base/src/GHC.Real.html#truncate"><span class="hs-identifier hs-var">truncate</span></a></span><span> </span><span class="annot"><span class="annottext">Rational
</span><a href="#local-6989586621681048786"><span class="hs-identifier hs-var">r</span></a></span><span>
</span><span id="line-171"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmVec"><span class="hs-identifier hs-type">CmmVec</span></a></span><span> </span><span id="local-6989586621681048783"><span class="annot"><span class="annottext">[CmmLit]
</span><a href="#local-6989586621681048783"><span class="hs-identifier hs-var">ls</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmLit -&gt; Word32) -&gt; [CmmLit] -&gt; Word32
forall {t :: * -&gt; *} {t}.
Foldable t =&gt;
(t -&gt; Word32) -&gt; t t -&gt; Word32
</span><a href="#local-6989586621681048829"><span class="hs-identifier hs-var">hash_list</span></a></span><span> </span><span class="annot"><span class="annottext">CmmLit -&gt; Word32
</span><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmLit]
</span><a href="#local-6989586621681048783"><span class="hs-identifier hs-var">ls</span></a></span><span>
</span><span id="line-172"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLabel"><span class="hs-identifier hs-type">CmmLabel</span></a></span><span> </span><span class="annot"><span class="annottext">CLabel
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">119</span></span><span> </span><span class="hs-comment">-- ugh</span><span>
</span><span id="line-173"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLabelOff"><span class="hs-identifier hs-type">CmmLabelOff</span></a></span><span> </span><span class="annot"><span class="annottext">CLabel
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681048780"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048780"><span class="hs-identifier hs-var">i</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Word32
</span><a href="#local-6989586621681048791"><span class="hs-identifier hs-var">cvt</span></a></span><span> </span><span class="annot"><span class="annottext">(Int -&gt; Word32) -&gt; Int -&gt; Word32
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">199</span></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048780"><span class="hs-identifier hs-var">i</span></a></span><span>
</span><span id="line-174"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLabelDiffOff"><span class="hs-identifier hs-type">CmmLabelDiffOff</span></a></span><span> </span><span class="annot"><span class="annottext">CLabel
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">CLabel
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681048778"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048778"><span class="hs-identifier hs-var">i</span></a></span></span><span> </span><span class="annot"><span class="annottext">Width
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Word32
</span><a href="#local-6989586621681048791"><span class="hs-identifier hs-var">cvt</span></a></span><span> </span><span class="annot"><span class="annottext">(Int -&gt; Word32) -&gt; Int -&gt; Word32
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">299</span></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048778"><span class="hs-identifier hs-var">i</span></a></span><span>
</span><span id="line-175"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">191</span></span><span> </span><span class="hs-comment">-- ugh</span><span>
</span><span id="line-176"></span><span>        </span><span class="annot"><a href="#local-6989586621681048801"><span class="hs-identifier hs-var">hash_lit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmLit
</span><a href="GHC.Cmm.Expr.html#CmmHighStackMark"><span class="hs-identifier hs-var">CmmHighStackMark</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Word32
</span><a href="#local-6989586621681048791"><span class="hs-identifier hs-var">cvt</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">313</span></span><span>
</span><span id="line-177"></span><span>
</span><span id="line-178"></span><span>        </span><span id="local-6989586621681048830"><span class="annot"><span class="annottext">hash_tgt :: ForeignTarget -&gt; Word32
</span><a href="#local-6989586621681048830"><span class="hs-identifier hs-var hs-var">hash_tgt</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#ForeignTarget"><span class="hs-identifier hs-type">ForeignTarget</span></a></span><span> </span><span id="local-6989586621681048773"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048773"><span class="hs-identifier hs-var">e</span></a></span></span><span> </span><span class="annot"><span class="annottext">ForeignConvention
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; Word32
</span><a href="#local-6989586621681048844"><span class="hs-identifier hs-var">hash_e</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048773"><span class="hs-identifier hs-var">e</span></a></span><span>
</span><span id="line-179"></span><span>        </span><span class="annot"><a href="#local-6989586621681048830"><span class="hs-identifier hs-var">hash_tgt</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#PrimTarget"><span class="hs-identifier hs-type">PrimTarget</span></a></span><span> </span><span class="annot"><span class="annottext">CallishMachOp
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">31</span></span><span> </span><span class="hs-comment">-- lots of these</span><span>
</span><span id="line-180"></span><span>
</span><span id="line-181"></span><span>        </span><span id="local-6989586621681048829"><span class="annot"><span class="annottext">hash_list :: (t -&gt; Word32) -&gt; t t -&gt; Word32
</span><a href="#local-6989586621681048829"><span class="hs-identifier hs-var hs-var">hash_list</span></a></span></span><span> </span><span id="local-6989586621681048767"><span class="annot"><span class="annottext">t -&gt; Word32
</span><a href="#local-6989586621681048767"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Word32 -&gt; t -&gt; Word32) -&gt; Word32 -&gt; t t -&gt; Word32
forall (t :: * -&gt; *) b a.
Foldable t =&gt;
(b -&gt; a -&gt; b) -&gt; b -&gt; t a -&gt; b
</span><a href="../../base/src/Data.Foldable.html#foldl%27"><span class="hs-identifier hs-var">foldl'</span></a></span><span> </span><span class="hs-special">(</span><span class="hs-glyph">\</span><span id="local-6989586621681048765"><span class="annot"><span class="annottext">Word32
</span><a href="#local-6989586621681048765"><span class="hs-identifier hs-var">z</span></a></span></span><span> </span><span id="local-6989586621681048764"><span class="annot"><span class="annottext">t
</span><a href="#local-6989586621681048764"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">t -&gt; Word32
</span><a href="#local-6989586621681048767"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">t
</span><a href="#local-6989586621681048764"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">Word32 -&gt; Word32 -&gt; Word32
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2B"><span class="hs-operator hs-var">+</span></a></span><span> </span><span class="annot"><span class="annottext">Word32
</span><a href="#local-6989586621681048765"><span class="hs-identifier hs-var">z</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Word32
</span><span class="hs-number">0</span></span><span class="hs-glyph">::</span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-182"></span><span>
</span><span id="line-183"></span><span>        </span><span id="local-6989586621681048791"><span class="annot"><span class="annottext">cvt :: Int -&gt; Word32
</span><a href="#local-6989586621681048791"><span class="hs-identifier hs-var hs-var">cvt</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Integer -&gt; Word32
forall a. Num a =&gt; Integer -&gt; a
</span><a href="../../base/src/GHC.Num.html#fromInteger"><span class="hs-identifier hs-var">fromInteger</span></a></span><span> </span><span class="annot"><span class="annottext">(Integer -&gt; Word32) -&gt; (Int -&gt; Integer) -&gt; Int -&gt; Word32
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Integer
forall a. Integral a =&gt; a -&gt; Integer
</span><a href="../../base/src/GHC.Real.html#toInteger"><span class="hs-identifier hs-var">toInteger</span></a></span><span>
</span><span id="line-184"></span><span>
</span><span id="line-185"></span><span>        </span><span id="local-6989586621681049122"><span class="annot"><a href="#local-6989586621681048805"><span class="hs-identifier hs-type">hash_unique</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Unique.html#Uniquable"><span class="hs-identifier hs-type">Uniquable</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681049122"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><a href="#local-6989586621681049122"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Word.html#Word32"><span class="hs-identifier hs-type">Word32</span></a></span></span><span>
</span><span id="line-186"></span><span>        </span><span id="local-6989586621681048805"><span class="annot"><span class="annottext">hash_unique :: forall a. Uniquable a =&gt; a -&gt; Word32
</span><a href="#local-6989586621681048805"><span class="hs-identifier hs-var hs-var">hash_unique</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; Word32
</span><a href="#local-6989586621681048791"><span class="hs-identifier hs-var">cvt</span></a></span><span> </span><span class="annot"><span class="annottext">(Int -&gt; Word32) -&gt; (a -&gt; Int) -&gt; a -&gt; Word32
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Unique -&gt; Int
</span><a href="GHC.Types.Unique.html#getKey"><span class="hs-identifier hs-var">getKey</span></a></span><span> </span><span class="annot"><span class="annottext">(Unique -&gt; Int) -&gt; (a -&gt; Unique) -&gt; a -&gt; Int
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; Unique
forall a. Uniquable a =&gt; a -&gt; Unique
</span><a href="GHC.Types.Unique.html#getUnique"><span class="hs-identifier hs-var">getUnique</span></a></span><span>
</span><span id="line-187"></span><span>
</span><span id="line-188"></span><span class="hs-comment">-- | Ignore these node types for equality</span><span>
</span><span id="line-189"></span><span id="local-6989586621681049131"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-type">dont_care</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmNode"><span class="hs-identifier hs-type">CmmNode</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681049131"><span class="hs-identifier hs-type">x</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span><span>
</span><span id="line-190"></span><span id="dont_care"><span class="annot"><span class="annottext">dont_care :: forall (x :: Extensibility). CmmNode O x -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var hs-var">dont_care</span></a></span></span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmComment"><span class="hs-identifier hs-type">CmmComment</span></a></span><span> </span><span class="hs-special">{</span><span class="hs-special">}</span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-191"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var">dont_care</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmTick"><span class="hs-identifier hs-type">CmmTick</span></a></span><span> </span><span class="hs-special">{</span><span class="hs-special">}</span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-192"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var">dont_care</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmUnwind"><span class="hs-identifier hs-type">CmmUnwind</span></a></span><span> </span><span class="hs-special">{</span><span class="hs-special">}</span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-193"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var">dont_care</span></a></span><span> </span><span id="local-6989586621681048746"><span class="annot"><span class="annottext">CmmNode O x
</span><a href="#local-6989586621681048746"><span class="hs-identifier hs-var">_other</span></a></span></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-194"></span><span>
</span><span id="line-195"></span><span class="hs-comment">-- Utilities: equality and substitution on the graph.</span><span>
</span><span id="line-196"></span><span>
</span><span id="line-197"></span><span class="hs-comment">-- Given a map ``subst'' from BlockID -&gt; BlockID, we define equality.</span><span>
</span><span id="line-198"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqBid"><span class="hs-identifier hs-type">eqBid</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html#LabelMap"><span class="hs-identifier hs-type">LabelMap</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-199"></span><span id="eqBid"><span class="annot"><span class="annottext">eqBid :: LabelMap BlockId -&gt; BlockId -&gt; BlockId -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqBid"><span class="hs-identifier hs-var hs-var">eqBid</span></a></span></span><span> </span><span id="local-6989586621681048745"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048745"><span class="hs-identifier hs-var">subst</span></a></span></span><span> </span><span id="local-6989586621681048744"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048744"><span class="hs-identifier hs-var">bid</span></a></span></span><span> </span><span id="local-6989586621681048743"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048743"><span class="hs-identifier hs-var">bid'</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; BlockId -&gt; BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#lookupBid"><span class="hs-identifier hs-var">lookupBid</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048745"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048744"><span class="hs-identifier hs-var">bid</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; BlockId -&gt; BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#lookupBid"><span class="hs-identifier hs-var">lookupBid</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048745"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048743"><span class="hs-identifier hs-var">bid'</span></a></span><span>
</span><span id="line-200"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#lookupBid"><span class="hs-identifier hs-type">lookupBid</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html#LabelMap"><span class="hs-identifier hs-type">LabelMap</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span>
</span><span id="line-201"></span><span id="lookupBid"><span class="annot"><span class="annottext">lookupBid :: LabelMap BlockId -&gt; BlockId -&gt; BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#lookupBid"><span class="hs-identifier hs-var hs-var">lookupBid</span></a></span></span><span> </span><span id="local-6989586621681048742"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048742"><span class="hs-identifier hs-var">subst</span></a></span></span><span> </span><span id="local-6989586621681048741"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048741"><span class="hs-identifier hs-var">bid</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">KeyOf LabelMap -&gt; LabelMap BlockId -&gt; Maybe BlockId
forall (map :: * -&gt; *) a.
IsMap map =&gt;
KeyOf map -&gt; map a -&gt; Maybe a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapLookup"><span class="hs-identifier hs-var">mapLookup</span></a></span><span> </span><span class="annot"><span class="annottext">KeyOf LabelMap
BlockId
</span><a href="#local-6989586621681048741"><span class="hs-identifier hs-var">bid</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048742"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-202"></span><span>                        </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621681048739"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048739"><span class="hs-identifier hs-var">bid</span></a></span></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; BlockId -&gt; BlockId
</span><a href="GHC.Cmm.CommonBlockElim.html#lookupBid"><span class="hs-identifier hs-var">lookupBid</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048742"><span class="hs-identifier hs-var">subst</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048739"><span class="hs-identifier hs-var">bid</span></a></span><span>
</span><span id="line-203"></span><span>                        </span><span class="annot"><span class="annottext">Maybe BlockId
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048741"><span class="hs-identifier hs-var">bid</span></a></span><span>
</span><span id="line-204"></span><span>
</span><span id="line-205"></span><span class="hs-comment">-- Middle nodes and expressions can contain BlockIds, in particular in</span><span>
</span><span id="line-206"></span><span class="hs-comment">-- CmmStackSlot and CmmBlock, so we have to use a special equality for</span><span>
</span><span id="line-207"></span><span class="hs-comment">-- these.</span><span>
</span><span id="line-208"></span><span class="hs-comment">--</span><span>
</span><span id="line-209"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMiddleWith"><span class="hs-identifier hs-type">eqMiddleWith</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span>
</span><span id="line-210"></span><span>             </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmNode"><span class="hs-identifier hs-type">CmmNode</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmNode"><span class="hs-identifier hs-type">CmmNode</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-211"></span><span id="eqMiddleWith"><span class="annot"><span class="annottext">eqMiddleWith :: (BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmNode O O -&gt; CmmNode O O -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqMiddleWith"><span class="hs-identifier hs-var hs-var">eqMiddleWith</span></a></span></span><span> </span><span id="local-6989586621681048737"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048737"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmAssign"><span class="hs-identifier hs-type">CmmAssign</span></a></span><span> </span><span id="local-6989586621681048734"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048734"><span class="hs-identifier hs-var">r1</span></a></span></span><span> </span><span id="local-6989586621681048733"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048733"><span class="hs-identifier hs-var">e1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmAssign"><span class="hs-identifier hs-type">CmmAssign</span></a></span><span> </span><span id="local-6989586621681048729"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048729"><span class="hs-identifier hs-var">r2</span></a></span></span><span> </span><span id="local-6989586621681048728"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048728"><span class="hs-identifier hs-var">e2</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-212"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048734"><span class="hs-identifier hs-var">r1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmReg -&gt; CmmReg -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048729"><span class="hs-identifier hs-var">r2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqExprWith"><span class="hs-identifier hs-var">eqExprWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048737"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048733"><span class="hs-identifier hs-var">e1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048728"><span class="hs-identifier hs-var">e2</span></a></span><span>
</span><span id="line-213"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMiddleWith"><span class="hs-identifier hs-var">eqMiddleWith</span></a></span><span> </span><span id="local-6989586621681048725"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048725"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmStore"><span class="hs-identifier hs-type">CmmStore</span></a></span><span> </span><span id="local-6989586621681048722"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048722"><span class="hs-identifier hs-var">l1</span></a></span></span><span> </span><span id="local-6989586621681048721"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048721"><span class="hs-identifier hs-var">r1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmStore"><span class="hs-identifier hs-type">CmmStore</span></a></span><span> </span><span id="local-6989586621681048718"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048718"><span class="hs-identifier hs-var">l2</span></a></span></span><span> </span><span id="local-6989586621681048717"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048717"><span class="hs-identifier hs-var">r2</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-214"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqExprWith"><span class="hs-identifier hs-var">eqExprWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048725"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048722"><span class="hs-identifier hs-var">l1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048718"><span class="hs-identifier hs-var">l2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqExprWith"><span class="hs-identifier hs-var">eqExprWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048725"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048721"><span class="hs-identifier hs-var">r1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048717"><span class="hs-identifier hs-var">r2</span></a></span><span>
</span><span id="line-215"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMiddleWith"><span class="hs-identifier hs-var">eqMiddleWith</span></a></span><span> </span><span id="local-6989586621681048716"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048716"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmUnsafeForeignCall"><span class="hs-identifier hs-type">CmmUnsafeForeignCall</span></a></span><span> </span><span id="local-6989586621681048713"><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048713"><span class="hs-identifier hs-var">t1</span></a></span></span><span> </span><span id="local-6989586621681048712"><span class="annot"><span class="annottext">[LocalReg]
</span><a href="#local-6989586621681048712"><span class="hs-identifier hs-var">r1</span></a></span></span><span> </span><span id="local-6989586621681048711"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048711"><span class="hs-identifier hs-var">a1</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-216"></span><span>                   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmUnsafeForeignCall"><span class="hs-identifier hs-type">CmmUnsafeForeignCall</span></a></span><span> </span><span id="local-6989586621681048702"><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048702"><span class="hs-identifier hs-var">t2</span></a></span></span><span> </span><span id="local-6989586621681048701"><span class="annot"><span class="annottext">[LocalReg]
</span><a href="#local-6989586621681048701"><span class="hs-identifier hs-var">r2</span></a></span></span><span> </span><span id="local-6989586621681048700"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048700"><span class="hs-identifier hs-var">a2</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-217"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048713"><span class="hs-identifier hs-var">t1</span></a></span><span> </span><span class="annot"><span class="annottext">ForeignTarget -&gt; ForeignTarget -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">ForeignTarget
</span><a href="#local-6989586621681048702"><span class="hs-identifier hs-var">t2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">[LocalReg]
</span><a href="#local-6989586621681048712"><span class="hs-identifier hs-var">r1</span></a></span><span> </span><span class="annot"><span class="annottext">[LocalReg] -&gt; [LocalReg] -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">[LocalReg]
</span><a href="#local-6989586621681048701"><span class="hs-identifier hs-var">r2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">(CmmExpr -&gt; CmmExpr -&gt; Bool) -&gt; [CmmExpr] -&gt; [CmmExpr] -&gt; Bool
forall a b. (a -&gt; b -&gt; Bool) -&gt; [a] -&gt; [b] -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var">eqListWith</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqExprWith"><span class="hs-identifier hs-var">eqExprWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048716"><span class="hs-identifier hs-var">eqBid</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048711"><span class="hs-identifier hs-var">a1</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048700"><span class="hs-identifier hs-var">a2</span></a></span><span>
</span><span id="line-218"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMiddleWith"><span class="hs-identifier hs-var">eqMiddleWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">CmmNode O O
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">CmmNode O O
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-219"></span><span>
</span><span id="line-220"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqExprWith"><span class="hs-identifier hs-type">eqExprWith</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span>
</span><span id="line-221"></span><span>           </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmExpr"><span class="hs-identifier hs-type">CmmExpr</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmExpr"><span class="hs-identifier hs-type">CmmExpr</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-222"></span><span id="eqExprWith"><span class="annot"><span class="annottext">eqExprWith :: (BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqExprWith"><span class="hs-identifier hs-var hs-var">eqExprWith</span></a></span></span><span> </span><span id="local-6989586621681048698"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048698"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="#local-6989586621681048697"><span class="hs-identifier hs-var">eq</span></a></span><span>
</span><span id="line-223"></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-224"></span><span>  </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLit"><span class="hs-identifier hs-type">CmmLit</span></a></span><span> </span><span id="local-6989586621681048696"><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048696"><span class="hs-identifier hs-var">l1</span></a></span></span><span>          </span><span id="local-6989586621681048697"><span class="annot"><span class="annottext">eq :: CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="#local-6989586621681048697"><span class="hs-operator hs-var hs-var">`eq`</span></a></span></span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLit"><span class="hs-identifier hs-type">CmmLit</span></a></span><span> </span><span id="local-6989586621681048695"><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048695"><span class="hs-identifier hs-var">l2</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmLit -&gt; CmmLit -&gt; Bool
</span><a href="#local-6989586621681048694"><span class="hs-identifier hs-var">eqLit</span></a></span><span> </span><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048696"><span class="hs-identifier hs-var">l1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048695"><span class="hs-identifier hs-var">l2</span></a></span><span>
</span><span id="line-225"></span><span>  </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLoad"><span class="hs-identifier hs-type">CmmLoad</span></a></span><span> </span><span id="local-6989586621681048693"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048693"><span class="hs-identifier hs-var">e1</span></a></span></span><span> </span><span class="annot"><span class="annottext">CmmType
</span><span class="hs-identifier">_</span></span><span>       </span><span class="annot"><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmLoad"><span class="hs-identifier hs-type">CmmLoad</span></a></span><span> </span><span id="local-6989586621681048692"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048692"><span class="hs-identifier hs-var">e2</span></a></span></span><span> </span><span class="annot"><span class="annottext">CmmType
</span><span class="hs-identifier">_</span></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048693"><span class="hs-identifier hs-var">e1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048692"><span class="hs-identifier hs-var">e2</span></a></span><span>
</span><span id="line-226"></span><span>  </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmReg"><span class="hs-identifier hs-type">CmmReg</span></a></span><span> </span><span id="local-6989586621681048691"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048691"><span class="hs-identifier hs-var">r1</span></a></span></span><span>          </span><span class="annot"><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmReg"><span class="hs-identifier hs-type">CmmReg</span></a></span><span> </span><span id="local-6989586621681048690"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048690"><span class="hs-identifier hs-var">r2</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048691"><span class="hs-identifier hs-var">r1</span></a></span><span class="annot"><span class="annottext">CmmReg -&gt; CmmReg -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048690"><span class="hs-identifier hs-var">r2</span></a></span><span>
</span><span id="line-227"></span><span>  </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmRegOff"><span class="hs-identifier hs-type">CmmRegOff</span></a></span><span> </span><span id="local-6989586621681048689"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048689"><span class="hs-identifier hs-var">r1</span></a></span></span><span> </span><span id="local-6989586621681048688"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048688"><span class="hs-identifier hs-var">i1</span></a></span></span><span>    </span><span class="annot"><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmRegOff"><span class="hs-identifier hs-type">CmmRegOff</span></a></span><span> </span><span id="local-6989586621681048687"><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048687"><span class="hs-identifier hs-var">r2</span></a></span></span><span> </span><span id="local-6989586621681048686"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048686"><span class="hs-identifier hs-var">i2</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048689"><span class="hs-identifier hs-var">r1</span></a></span><span class="annot"><span class="annottext">CmmReg -&gt; CmmReg -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span class="annot"><span class="annottext">CmmReg
</span><a href="#local-6989586621681048687"><span class="hs-identifier hs-var">r2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048688"><span class="hs-identifier hs-var">i1</span></a></span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048686"><span class="hs-identifier hs-var">i2</span></a></span><span>
</span><span id="line-228"></span><span>  </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmMachOp"><span class="hs-identifier hs-type">CmmMachOp</span></a></span><span> </span><span id="local-6989586621681048685"><span class="annot"><span class="annottext">MachOp
</span><a href="#local-6989586621681048685"><span class="hs-identifier hs-var">op1</span></a></span></span><span> </span><span id="local-6989586621681048684"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048684"><span class="hs-identifier hs-var">es1</span></a></span></span><span>  </span><span class="annot"><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmMachOp"><span class="hs-identifier hs-type">CmmMachOp</span></a></span><span> </span><span id="local-6989586621681048683"><span class="annot"><span class="annottext">MachOp
</span><a href="#local-6989586621681048683"><span class="hs-identifier hs-var">op2</span></a></span></span><span> </span><span id="local-6989586621681048682"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048682"><span class="hs-identifier hs-var">es2</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">MachOp
</span><a href="#local-6989586621681048685"><span class="hs-identifier hs-var">op1</span></a></span><span class="annot"><span class="annottext">MachOp -&gt; MachOp -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span class="annot"><span class="annottext">MachOp
</span><a href="#local-6989586621681048683"><span class="hs-identifier hs-var">op2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048684"><span class="hs-identifier hs-var">es1</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr] -&gt; [CmmExpr] -&gt; Bool
</span><a href="#local-6989586621681048681"><span class="hs-operator hs-var">`eqs`</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048682"><span class="hs-identifier hs-var">es2</span></a></span><span>
</span><span id="line-229"></span><span>  </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmStackSlot"><span class="hs-identifier hs-type">CmmStackSlot</span></a></span><span> </span><span id="local-6989586621681048680"><span class="annot"><span class="annottext">Area
</span><a href="#local-6989586621681048680"><span class="hs-identifier hs-var">a1</span></a></span></span><span> </span><span id="local-6989586621681048679"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048679"><span class="hs-identifier hs-var">i1</span></a></span></span><span> </span><span class="annot"><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmStackSlot"><span class="hs-identifier hs-type">CmmStackSlot</span></a></span><span> </span><span id="local-6989586621681048678"><span class="annot"><span class="annottext">Area
</span><a href="#local-6989586621681048678"><span class="hs-identifier hs-var">a2</span></a></span></span><span> </span><span id="local-6989586621681048677"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048677"><span class="hs-identifier hs-var">i2</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Area -&gt; Area -&gt; Bool
</span><a href="#local-6989586621681048676"><span class="hs-identifier hs-var">eqArea</span></a></span><span> </span><span class="annot"><span class="annottext">Area
</span><a href="#local-6989586621681048680"><span class="hs-identifier hs-var">a1</span></a></span><span> </span><span class="annot"><span class="annottext">Area
</span><a href="#local-6989586621681048678"><span class="hs-identifier hs-var">a2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048679"><span class="hs-identifier hs-var">i1</span></a></span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048677"><span class="hs-identifier hs-var">i2</span></a></span><span>
</span><span id="line-230"></span><span>  </span><span id="local-6989586621681048675"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048675"><span class="hs-identifier hs-var">_e1</span></a></span></span><span>                </span><span class="annot"><a href="#local-6989586621681048697"><span class="hs-operator hs-var">`eq`</span></a></span><span> </span><span id="local-6989586621681048674"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048674"><span class="hs-identifier hs-var">_e2</span></a></span></span><span>                </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-231"></span><span>
</span><span id="line-232"></span><span>  </span><span id="local-6989586621681048673"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048673"><span class="hs-identifier hs-var">xs</span></a></span></span><span> </span><span id="local-6989586621681048681"><span class="annot"><span class="annottext">eqs :: [CmmExpr] -&gt; [CmmExpr] -&gt; Bool
</span><a href="#local-6989586621681048681"><span class="hs-operator hs-var hs-var">`eqs`</span></a></span></span><span> </span><span id="local-6989586621681048672"><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048672"><span class="hs-identifier hs-var">ys</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmExpr -&gt; CmmExpr -&gt; Bool) -&gt; [CmmExpr] -&gt; [CmmExpr] -&gt; Bool
forall a b. (a -&gt; b -&gt; Bool) -&gt; [a] -&gt; [b] -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var">eqListWith</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; CmmExpr -&gt; Bool
</span><a href="#local-6989586621681048697"><span class="hs-identifier hs-var">eq</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048673"><span class="hs-identifier hs-var">xs</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmExpr]
</span><a href="#local-6989586621681048672"><span class="hs-identifier hs-var">ys</span></a></span><span>
</span><span id="line-233"></span><span>
</span><span id="line-234"></span><span>  </span><span id="local-6989586621681048694"><span class="annot"><span class="annottext">eqLit :: CmmLit -&gt; CmmLit -&gt; Bool
</span><a href="#local-6989586621681048694"><span class="hs-identifier hs-var hs-var">eqLit</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span> </span><span id="local-6989586621681048671"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048671"><span class="hs-identifier hs-var">id1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span> </span><span id="local-6989586621681048670"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048670"><span class="hs-identifier hs-var">id2</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048698"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048671"><span class="hs-identifier hs-var">id1</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048670"><span class="hs-identifier hs-var">id2</span></a></span><span>
</span><span id="line-235"></span><span>  </span><span class="annot"><a href="#local-6989586621681048694"><span class="hs-identifier hs-var">eqLit</span></a></span><span> </span><span id="local-6989586621681048669"><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048669"><span class="hs-identifier hs-var">l1</span></a></span></span><span> </span><span id="local-6989586621681048668"><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048668"><span class="hs-identifier hs-var">l2</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048669"><span class="hs-identifier hs-var">l1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmLit -&gt; CmmLit -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">CmmLit
</span><a href="#local-6989586621681048668"><span class="hs-identifier hs-var">l2</span></a></span><span>
</span><span id="line-236"></span><span>
</span><span id="line-237"></span><span>  </span><span id="local-6989586621681048676"><span class="annot"><span class="annottext">eqArea :: Area -&gt; Area -&gt; Bool
</span><a href="#local-6989586621681048676"><span class="hs-identifier hs-var hs-var">eqArea</span></a></span></span><span> </span><span class="annot"><span class="annottext">Area
</span><a href="GHC.Cmm.Expr.html#Old"><span class="hs-identifier hs-var">Old</span></a></span><span> </span><span class="annot"><span class="annottext">Area
</span><a href="GHC.Cmm.Expr.html#Old"><span class="hs-identifier hs-var">Old</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-238"></span><span>  </span><span class="annot"><a href="#local-6989586621681048676"><span class="hs-identifier hs-var">eqArea</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#Young"><span class="hs-identifier hs-type">Young</span></a></span><span> </span><span id="local-6989586621681048665"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048665"><span class="hs-identifier hs-var">id1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Expr.html#Young"><span class="hs-identifier hs-type">Young</span></a></span><span> </span><span id="local-6989586621681048664"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048664"><span class="hs-identifier hs-var">id2</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048698"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048665"><span class="hs-identifier hs-var">id1</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048664"><span class="hs-identifier hs-var">id2</span></a></span><span>
</span><span id="line-239"></span><span>  </span><span class="annot"><a href="#local-6989586621681048676"><span class="hs-identifier hs-var">eqArea</span></a></span><span> </span><span class="annot"><span class="annottext">Area
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Area
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-240"></span><span>
</span><span id="line-241"></span><span class="hs-comment">-- Equality on the body of a block, modulo a function mapping block</span><span>
</span><span id="line-242"></span><span class="hs-comment">-- IDs to block IDs.</span><span>
</span><span id="line-243"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqBlockBodyWith"><span class="hs-identifier hs-type">eqBlockBodyWith</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmBlock"><span class="hs-identifier hs-type">CmmBlock</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-244"></span><span id="eqBlockBodyWith"><span class="annot"><span class="annottext">eqBlockBodyWith :: (BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmBlock -&gt; CmmBlock -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqBlockBodyWith"><span class="hs-identifier hs-var hs-var">eqBlockBodyWith</span></a></span></span><span> </span><span id="local-6989586621681048663"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048663"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span id="local-6989586621681048662"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048662"><span class="hs-identifier hs-var">block</span></a></span></span><span> </span><span id="local-6989586621681048661"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048661"><span class="hs-identifier hs-var">block'</span></a></span></span><span>
</span><span id="line-245"></span><span>  </span><span class="hs-comment">{-
  | equal     = pprTrace &quot;equal&quot; (vcat [ppr block, ppr block']) True
  | otherwise = pprTrace &quot;not equal&quot; (vcat [ppr block, ppr block']) False
  -}</span><span>
</span><span id="line-249"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="#local-6989586621681048660"><span class="hs-identifier hs-var">equal</span></a></span><span>
</span><span id="line-250"></span><span>  </span><span class="hs-keyword">where</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmNode C O
</span><span class="hs-identifier">_</span></span><span class="hs-special">,</span><span id="local-6989586621681048659"><span class="annot"><span class="annottext">Block CmmNode O O
</span><a href="#local-6989586621681048659"><span class="hs-identifier hs-var">m</span></a></span></span><span class="hs-special">,</span><span id="local-6989586621681048658"><span class="annot"><span class="annottext">CmmNode O C
</span><a href="#local-6989586621681048658"><span class="hs-identifier hs-var">l</span></a></span></span><span class="hs-special">)</span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; (CmmNode C O, Block CmmNode O O, CmmNode O C)
forall (n :: Extensibility -&gt; Extensibility -&gt; *).
Block n C C -&gt; (n C O, Block n O O, n O C)
</span><a href="GHC.Cmm.Dataflow.Block.html#blockSplit"><span class="hs-identifier hs-var">blockSplit</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048662"><span class="hs-identifier hs-var">block</span></a></span><span>
</span><span id="line-251"></span><span>        </span><span id="local-6989586621681048656"><span class="annot"><span class="annottext">nodes :: [CmmNode O O]
</span><a href="#local-6989586621681048656"><span class="hs-identifier hs-var hs-var">nodes</span></a></span></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmNode O O -&gt; Bool) -&gt; [CmmNode O O] -&gt; [CmmNode O O]
forall a. (a -&gt; Bool) -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.List.html#filter"><span class="hs-identifier hs-var">filter</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Bool -&gt; Bool
</span><span class="hs-identifier hs-var">not</span></span><span> </span><span class="annot"><span class="annottext">(Bool -&gt; Bool) -&gt; (CmmNode O O -&gt; Bool) -&gt; CmmNode O O -&gt; Bool
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O O -&gt; Bool
forall (x :: Extensibility). CmmNode O x -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var">dont_care</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Block CmmNode O O -&gt; [CmmNode O O]
forall (n :: Extensibility -&gt; Extensibility -&gt; *).
Block n O O -&gt; [n O O]
</span><a href="GHC.Cmm.Dataflow.Block.html#blockToList"><span class="hs-identifier hs-var">blockToList</span></a></span><span> </span><span class="annot"><span class="annottext">Block CmmNode O O
</span><a href="#local-6989586621681048659"><span class="hs-identifier hs-var">m</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-252"></span><span>        </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmNode C O
</span><span class="hs-identifier">_</span></span><span class="hs-special">,</span><span id="local-6989586621681048653"><span class="annot"><span class="annottext">Block CmmNode O O
</span><a href="#local-6989586621681048653"><span class="hs-identifier hs-var">m'</span></a></span></span><span class="hs-special">,</span><span id="local-6989586621681048652"><span class="annot"><span class="annottext">CmmNode O C
</span><a href="#local-6989586621681048652"><span class="hs-identifier hs-var">l'</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; (CmmNode C O, Block CmmNode O O, CmmNode O C)
forall (n :: Extensibility -&gt; Extensibility -&gt; *).
Block n C C -&gt; (n C O, Block n O O, n O C)
</span><a href="GHC.Cmm.Dataflow.Block.html#blockSplit"><span class="hs-identifier hs-var">blockSplit</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048661"><span class="hs-identifier hs-var">block'</span></a></span><span>
</span><span id="line-253"></span><span>        </span><span id="local-6989586621681048651"><span class="annot"><span class="annottext">nodes' :: [CmmNode O O]
</span><a href="#local-6989586621681048651"><span class="hs-identifier hs-var hs-var">nodes'</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmNode O O -&gt; Bool) -&gt; [CmmNode O O] -&gt; [CmmNode O O]
forall a. (a -&gt; Bool) -&gt; [a] -&gt; [a]
</span><a href="../../base/src/GHC.List.html#filter"><span class="hs-identifier hs-var">filter</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Bool -&gt; Bool
</span><span class="hs-identifier hs-var">not</span></span><span> </span><span class="annot"><span class="annottext">(Bool -&gt; Bool) -&gt; (CmmNode O O -&gt; Bool) -&gt; CmmNode O O -&gt; Bool
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O O -&gt; Bool
forall (x :: Extensibility). CmmNode O x -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#dont_care"><span class="hs-identifier hs-var">dont_care</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Block CmmNode O O -&gt; [CmmNode O O]
forall (n :: Extensibility -&gt; Extensibility -&gt; *).
Block n O O -&gt; [n O O]
</span><a href="GHC.Cmm.Dataflow.Block.html#blockToList"><span class="hs-identifier hs-var">blockToList</span></a></span><span> </span><span class="annot"><span class="annottext">Block CmmNode O O
</span><a href="#local-6989586621681048653"><span class="hs-identifier hs-var">m'</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-254"></span><span>
</span><span id="line-255"></span><span>        </span><span id="local-6989586621681048660"><span class="annot"><span class="annottext">equal :: Bool
</span><a href="#local-6989586621681048660"><span class="hs-identifier hs-var hs-var">equal</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(CmmNode O O -&gt; CmmNode O O -&gt; Bool)
-&gt; [CmmNode O O] -&gt; [CmmNode O O] -&gt; Bool
forall a b. (a -&gt; b -&gt; Bool) -&gt; [a] -&gt; [b] -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var">eqListWith</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmNode O O -&gt; CmmNode O O -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqMiddleWith"><span class="hs-identifier hs-var">eqMiddleWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048663"><span class="hs-identifier hs-var">eqBid</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[CmmNode O O]
</span><a href="#local-6989586621681048656"><span class="hs-identifier hs-var">nodes</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmNode O O]
</span><a href="#local-6989586621681048651"><span class="hs-identifier hs-var">nodes'</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span>
</span><span id="line-256"></span><span>                </span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmNode O C -&gt; CmmNode O C -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-var">eqLastWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048663"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O C
</span><a href="#local-6989586621681048658"><span class="hs-identifier hs-var">l</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O C
</span><a href="#local-6989586621681048652"><span class="hs-identifier hs-var">l'</span></a></span><span>
</span><span id="line-257"></span><span>
</span><span id="line-258"></span><span>
</span><span id="line-259"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-type">eqLastWith</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmNode"><span class="hs-identifier hs-type">CmmNode</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#C"><span class="hs-identifier hs-type">C</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmNode"><span class="hs-identifier hs-type">CmmNode</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#O"><span class="hs-identifier hs-type">O</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Block.html#C"><span class="hs-identifier hs-type">C</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-260"></span><span id="eqLastWith"><span class="annot"><span class="annottext">eqLastWith :: (BlockId -&gt; BlockId -&gt; Bool) -&gt; CmmNode O C -&gt; CmmNode O C -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-var hs-var">eqLastWith</span></a></span></span><span> </span><span id="local-6989586621681048649"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048649"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmBranch"><span class="hs-identifier hs-type">CmmBranch</span></a></span><span> </span><span id="local-6989586621681048646"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048646"><span class="hs-identifier hs-var">bid1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmBranch"><span class="hs-identifier hs-type">CmmBranch</span></a></span><span> </span><span id="local-6989586621681048643"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048643"><span class="hs-identifier hs-var">bid2</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048649"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048646"><span class="hs-identifier hs-var">bid1</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048643"><span class="hs-identifier hs-var">bid2</span></a></span><span>
</span><span id="line-261"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-var">eqLastWith</span></a></span><span> </span><span id="local-6989586621681048642"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048642"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmCondBranch"><span class="hs-identifier hs-type">CmmCondBranch</span></a></span><span> </span><span id="local-6989586621681048639"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048639"><span class="hs-identifier hs-var">c1</span></a></span></span><span> </span><span id="local-6989586621681048638"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048638"><span class="hs-identifier hs-var">t1</span></a></span></span><span> </span><span id="local-6989586621681048637"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048637"><span class="hs-identifier hs-var">f1</span></a></span></span><span> </span><span id="local-6989586621681048636"><span class="annot"><span class="annottext">Maybe Bool
</span><a href="#local-6989586621681048636"><span class="hs-identifier hs-var">l1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmCondBranch"><span class="hs-identifier hs-type">CmmCondBranch</span></a></span><span> </span><span id="local-6989586621681048627"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048627"><span class="hs-identifier hs-var">c2</span></a></span></span><span> </span><span id="local-6989586621681048626"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048626"><span class="hs-identifier hs-var">t2</span></a></span></span><span> </span><span id="local-6989586621681048625"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048625"><span class="hs-identifier hs-var">f2</span></a></span></span><span> </span><span id="local-6989586621681048624"><span class="annot"><span class="annottext">Maybe Bool
</span><a href="#local-6989586621681048624"><span class="hs-identifier hs-var">l2</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-262"></span><span>  </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048639"><span class="hs-identifier hs-var">c1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; CmmExpr -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048627"><span class="hs-identifier hs-var">c2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Maybe Bool
</span><a href="#local-6989586621681048636"><span class="hs-identifier hs-var">l1</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe Bool -&gt; Maybe Bool -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">Maybe Bool
</span><a href="#local-6989586621681048624"><span class="hs-identifier hs-var">l2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048642"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048638"><span class="hs-identifier hs-var">t1</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048626"><span class="hs-identifier hs-var">t2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048642"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048637"><span class="hs-identifier hs-var">f1</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048625"><span class="hs-identifier hs-var">f2</span></a></span><span>
</span><span id="line-263"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-var">eqLastWith</span></a></span><span> </span><span id="local-6989586621681048623"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048623"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmCall"><span class="hs-identifier hs-type">CmmCall</span></a></span><span> </span><span id="local-6989586621681048620"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048620"><span class="hs-identifier hs-var">t1</span></a></span></span><span> </span><span id="local-6989586621681048619"><span class="annot"><span class="annottext">Maybe BlockId
</span><a href="#local-6989586621681048619"><span class="hs-identifier hs-var">c1</span></a></span></span><span> </span><span id="local-6989586621681048618"><span class="annot"><span class="annottext">[GlobalReg]
</span><a href="#local-6989586621681048618"><span class="hs-identifier hs-var">g1</span></a></span></span><span> </span><span id="local-6989586621681048617"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048617"><span class="hs-identifier hs-var">a1</span></a></span></span><span> </span><span id="local-6989586621681048616"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048616"><span class="hs-identifier hs-var">r1</span></a></span></span><span> </span><span id="local-6989586621681048615"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048615"><span class="hs-identifier hs-var">u1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmCall"><span class="hs-identifier hs-type">CmmCall</span></a></span><span> </span><span id="local-6989586621681048605"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048605"><span class="hs-identifier hs-var">t2</span></a></span></span><span> </span><span id="local-6989586621681048604"><span class="annot"><span class="annottext">Maybe BlockId
</span><a href="#local-6989586621681048604"><span class="hs-identifier hs-var">c2</span></a></span></span><span> </span><span id="local-6989586621681048603"><span class="annot"><span class="annottext">[GlobalReg]
</span><a href="#local-6989586621681048603"><span class="hs-identifier hs-var">g2</span></a></span></span><span> </span><span id="local-6989586621681048602"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048602"><span class="hs-identifier hs-var">a2</span></a></span></span><span> </span><span id="local-6989586621681048601"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048601"><span class="hs-identifier hs-var">r2</span></a></span></span><span> </span><span id="local-6989586621681048600"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048600"><span class="hs-identifier hs-var">u2</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-264"></span><span>  </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048620"><span class="hs-identifier hs-var">t1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; CmmExpr -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048605"><span class="hs-identifier hs-var">t2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool)
-&gt; Maybe BlockId -&gt; Maybe BlockId -&gt; Bool
forall a b. (a -&gt; b -&gt; Bool) -&gt; Maybe a -&gt; Maybe b -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqMaybeWith"><span class="hs-identifier hs-var">eqMaybeWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048623"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe BlockId
</span><a href="#local-6989586621681048619"><span class="hs-identifier hs-var">c1</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe BlockId
</span><a href="#local-6989586621681048604"><span class="hs-identifier hs-var">c2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048617"><span class="hs-identifier hs-var">a1</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048602"><span class="hs-identifier hs-var">a2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048616"><span class="hs-identifier hs-var">r1</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048601"><span class="hs-identifier hs-var">r2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048615"><span class="hs-identifier hs-var">u1</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681048600"><span class="hs-identifier hs-var">u2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">[GlobalReg]
</span><a href="#local-6989586621681048618"><span class="hs-identifier hs-var">g1</span></a></span><span> </span><span class="annot"><span class="annottext">[GlobalReg] -&gt; [GlobalReg] -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">[GlobalReg]
</span><a href="#local-6989586621681048603"><span class="hs-identifier hs-var">g2</span></a></span><span>
</span><span id="line-265"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-var">eqLastWith</span></a></span><span> </span><span id="local-6989586621681048598"><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048598"><span class="hs-identifier hs-var">eqBid</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmSwitch"><span class="hs-identifier hs-type">CmmSwitch</span></a></span><span> </span><span id="local-6989586621681048595"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048595"><span class="hs-identifier hs-var">e1</span></a></span></span><span> </span><span id="local-6989586621681048594"><span class="annot"><span class="annottext">SwitchTargets
</span><a href="#local-6989586621681048594"><span class="hs-identifier hs-var">ids1</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmSwitch"><span class="hs-identifier hs-type">CmmSwitch</span></a></span><span> </span><span id="local-6989586621681048590"><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048590"><span class="hs-identifier hs-var">e2</span></a></span></span><span> </span><span id="local-6989586621681048589"><span class="annot"><span class="annottext">SwitchTargets
</span><a href="#local-6989586621681048589"><span class="hs-identifier hs-var">ids2</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-266"></span><span>  </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048595"><span class="hs-identifier hs-var">e1</span></a></span><span> </span><span class="annot"><span class="annottext">CmmExpr -&gt; CmmExpr -&gt; Bool
forall a. Eq a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">==</span></span><span> </span><span class="annot"><span class="annottext">CmmExpr
</span><a href="#local-6989586621681048590"><span class="hs-identifier hs-var">e2</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">(BlockId -&gt; BlockId -&gt; Bool)
-&gt; SwitchTargets -&gt; SwitchTargets -&gt; Bool
</span><a href="GHC.Cmm.Switch.html#eqSwitchTargetWith"><span class="hs-identifier hs-var">eqSwitchTargetWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><a href="#local-6989586621681048598"><span class="hs-identifier hs-var">eqBid</span></a></span><span> </span><span class="annot"><span class="annottext">SwitchTargets
</span><a href="#local-6989586621681048594"><span class="hs-identifier hs-var">ids1</span></a></span><span> </span><span class="annot"><span class="annottext">SwitchTargets
</span><a href="#local-6989586621681048589"><span class="hs-identifier hs-var">ids2</span></a></span><span>
</span><span id="line-267"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqLastWith"><span class="hs-identifier hs-var">eqLastWith</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; BlockId -&gt; Bool
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">CmmNode O C
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">CmmNode O C
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-268"></span><span>
</span><span id="line-269"></span><span id="local-6989586621681049092"><span id="local-6989586621681049093"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMaybeWith"><span class="hs-identifier hs-type">eqMaybeWith</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621681049093"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621681049092"><span class="hs-identifier hs-type">b</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681049093"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681049092"><span class="hs-identifier hs-type">b</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span></span><span>
</span><span id="line-270"></span><span id="eqMaybeWith"><span class="annot"><span class="annottext">eqMaybeWith :: forall a b. (a -&gt; b -&gt; Bool) -&gt; Maybe a -&gt; Maybe b -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqMaybeWith"><span class="hs-identifier hs-var hs-var">eqMaybeWith</span></a></span></span><span> </span><span id="local-6989586621681048588"><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><a href="#local-6989586621681048588"><span class="hs-identifier hs-var">eltEq</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621681048587"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048587"><span class="hs-identifier hs-var">e</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621681048586"><span class="annot"><span class="annottext">b
</span><a href="#local-6989586621681048586"><span class="hs-identifier hs-var">e'</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><a href="#local-6989586621681048588"><span class="hs-identifier hs-var">eltEq</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048587"><span class="hs-identifier hs-var">e</span></a></span><span> </span><span class="annot"><span class="annottext">b
</span><a href="#local-6989586621681048586"><span class="hs-identifier hs-var">e'</span></a></span><span>
</span><span id="line-271"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMaybeWith"><span class="hs-identifier hs-var">eqMaybeWith</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe b
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-272"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqMaybeWith"><span class="hs-identifier hs-var">eqMaybeWith</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Maybe a
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">Maybe b
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-273"></span><span>
</span><span id="line-274"></span><span id="local-6989586621681049098"><span id="local-6989586621681049099"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-type">eqListWith</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621681049099"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621681049098"><span class="hs-identifier hs-type">b</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621681049099"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621681049098"><span class="hs-identifier hs-type">b</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span></span><span>
</span><span id="line-275"></span><span id="eqListWith"><span class="annot"><span class="annottext">eqListWith :: forall a b. (a -&gt; b -&gt; Bool) -&gt; [a] -&gt; [b] -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var hs-var">eqListWith</span></a></span></span><span> </span><span id="local-6989586621681048585"><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><a href="#local-6989586621681048585"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span class="hs-special">(</span><span id="local-6989586621681048584"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048584"><span class="hs-identifier hs-var">a</span></a></span></span><span> </span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span> </span><span id="local-6989586621681048583"><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681048583"><span class="hs-keyword hs-var">as</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681048582"><span class="annot"><span class="annottext">b
</span><a href="#local-6989586621681048582"><span class="hs-identifier hs-var">b</span></a></span></span><span> </span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span> </span><span id="local-6989586621681048581"><span class="annot"><span class="annottext">[b]
</span><a href="#local-6989586621681048581"><span class="hs-identifier hs-var">bs</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><a href="#local-6989586621681048585"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048584"><span class="hs-identifier hs-var">a</span></a></span><span> </span><span class="annot"><span class="annottext">b
</span><a href="#local-6989586621681048582"><span class="hs-identifier hs-var">b</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">(a -&gt; b -&gt; Bool) -&gt; [a] -&gt; [b] -&gt; Bool
forall a b. (a -&gt; b -&gt; Bool) -&gt; [a] -&gt; [b] -&gt; Bool
</span><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var">eqListWith</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><a href="#local-6989586621681048585"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681048583"><span class="hs-keyword hs-var">as</span></a></span><span> </span><span class="annot"><span class="annottext">[b]
</span><a href="#local-6989586621681048581"><span class="hs-identifier hs-var">bs</span></a></span><span>
</span><span id="line-276"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var">eqListWith</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>       </span><span class="hs-special">[</span><span class="hs-special">]</span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-277"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#eqListWith"><span class="hs-identifier hs-var">eqListWith</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; Bool
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">[a]
</span><span class="hs-identifier">_</span></span><span>        </span><span class="annot"><span class="annottext">[b]
</span><span class="hs-identifier">_</span></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-278"></span><span>
</span><span id="line-279"></span><span class="hs-comment">-- | Given a block map, ensure that all &quot;target&quot; blocks are covered by</span><span>
</span><span id="line-280"></span><span class="hs-comment">-- the same ticks as the respective &quot;source&quot; blocks. This not only</span><span>
</span><span id="line-281"></span><span class="hs-comment">-- means copying ticks, but also adjusting tick scopes where</span><span>
</span><span id="line-282"></span><span class="hs-comment">-- necessary.</span><span>
</span><span id="line-283"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#copyTicks"><span class="hs-identifier hs-type">copyTicks</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html#LabelMap"><span class="hs-identifier hs-type">LabelMap</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.BlockId.html#BlockId"><span class="hs-identifier hs-type">BlockId</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmGraph"><span class="hs-identifier hs-type">CmmGraph</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Cmm.html#CmmGraph"><span class="hs-identifier hs-type">CmmGraph</span></a></span><span>
</span><span id="line-284"></span><span id="copyTicks"><span class="annot"><span class="annottext">copyTicks :: LabelMap BlockId -&gt; CmmGraph -&gt; CmmGraph
</span><a href="GHC.Cmm.CommonBlockElim.html#copyTicks"><span class="hs-identifier hs-var hs-var">copyTicks</span></a></span></span><span> </span><span id="local-6989586621681048580"><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048580"><span class="hs-identifier hs-var">env</span></a></span></span><span> </span><span id="local-6989586621681048579"><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048579"><span class="hs-identifier hs-var">g</span></a></span></span><span>
</span><span id="line-285"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId -&gt; Bool
forall (map :: * -&gt; *) a. IsMap map =&gt; map a -&gt; Bool
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapNull"><span class="hs-identifier hs-var">mapNull</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048580"><span class="hs-identifier hs-var">env</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048579"><span class="hs-identifier hs-var">g</span></a></span><span>
</span><span id="line-286"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; LabelMap CmmBlock -&gt; CmmGraph
</span><a href="GHC.Cmm.Utils.html#ofBlockMap"><span class="hs-identifier hs-var">ofBlockMap</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmGraph -&gt; BlockId
forall (n :: Extensibility -&gt; Extensibility -&gt; *).
GenCmmGraph n -&gt; BlockId
</span><a href="GHC.Cmm.html#g_entry"><span class="hs-identifier hs-var hs-var">g_entry</span></a></span><span> </span><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048579"><span class="hs-identifier hs-var">g</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">(LabelMap CmmBlock -&gt; CmmGraph) -&gt; LabelMap CmmBlock -&gt; CmmGraph
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">(CmmBlock -&gt; CmmBlock) -&gt; LabelMap CmmBlock -&gt; LabelMap CmmBlock
forall (map :: * -&gt; *) a b. IsMap map =&gt; (a -&gt; b) -&gt; map a -&gt; map b
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapMap"><span class="hs-identifier hs-var">mapMap</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; CmmBlock
</span><a href="#local-6989586621681048575"><span class="hs-identifier hs-var">copyTo</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap CmmBlock
</span><a href="#local-6989586621681048574"><span class="hs-identifier hs-var">blockMap</span></a></span><span>
</span><span id="line-287"></span><span>  </span><span class="hs-keyword">where</span><span> </span><span class="hs-comment">-- Reverse block merge map</span><span>
</span><span id="line-288"></span><span>        </span><span id="local-6989586621681048574"><span class="annot"><span class="annottext">blockMap :: LabelMap CmmBlock
</span><a href="#local-6989586621681048574"><span class="hs-identifier hs-var hs-var">blockMap</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmGraph -&gt; LabelMap CmmBlock
</span><a href="GHC.Cmm.Utils.html#toBlockMap"><span class="hs-identifier hs-var">toBlockMap</span></a></span><span> </span><span class="annot"><span class="annottext">CmmGraph
</span><a href="#local-6989586621681048579"><span class="hs-identifier hs-var">g</span></a></span><span>
</span><span id="line-289"></span><span>        </span><span id="local-6989586621681048572"><span class="annot"><span class="annottext">revEnv :: Map BlockId Key
</span><a href="#local-6989586621681048572"><span class="hs-identifier hs-var hs-var">revEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Map BlockId Key -&gt; KeyOf LabelMap -&gt; BlockId -&gt; Map BlockId Key)
-&gt; Map BlockId Key -&gt; LabelMap BlockId -&gt; Map BlockId Key
forall (map :: * -&gt; *) b a.
IsMap map =&gt;
(b -&gt; KeyOf map -&gt; a -&gt; b) -&gt; b -&gt; map a -&gt; b
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapFoldlWithKey"><span class="hs-identifier hs-var">mapFoldlWithKey</span></a></span><span> </span><span class="annot"><span class="annottext">Map BlockId Key -&gt; KeyOf LabelMap -&gt; BlockId -&gt; Map BlockId Key
forall {k} {a}. Ord k =&gt; Map k [a] -&gt; a -&gt; k -&gt; Map k [a]
</span><a href="#local-6989586621681048570"><span class="hs-identifier hs-var">insertRev</span></a></span><span> </span><span class="annot"><span class="annottext">Map BlockId Key
forall k a. Map k a
</span><a href="../../containers/src/Data.Map.Internal.html#empty"><span class="hs-identifier hs-var">M.empty</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap BlockId
</span><a href="#local-6989586621681048580"><span class="hs-identifier hs-var">env</span></a></span><span>
</span><span id="line-290"></span><span>        </span><span id="local-6989586621681048570"><span class="annot"><span class="annottext">insertRev :: Map k [a] -&gt; a -&gt; k -&gt; Map k [a]
</span><a href="#local-6989586621681048570"><span class="hs-identifier hs-var hs-var">insertRev</span></a></span></span><span> </span><span id="local-6989586621681048566"><span class="annot"><span class="annottext">Map k [a]
</span><a href="#local-6989586621681048566"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span id="local-6989586621681048565"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048565"><span class="hs-identifier hs-var">k</span></a></span></span><span> </span><span id="local-6989586621681048564"><span class="annot"><span class="annottext">k
</span><a href="#local-6989586621681048564"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">([a] -&gt; [a] -&gt; [a]) -&gt; k -&gt; [a] -&gt; Map k [a] -&gt; Map k [a]
forall k a. Ord k =&gt; (a -&gt; a -&gt; a) -&gt; k -&gt; a -&gt; Map k a -&gt; Map k a
</span><a href="../../containers/src/Data.Map.Internal.html#insertWith"><span class="hs-identifier hs-var">M.insertWith</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">([a] -&gt; [a]) -&gt; [a] -&gt; [a] -&gt; [a]
forall a b. a -&gt; b -&gt; a
</span><a href="../../base/src/GHC.Base.html#const"><span class="hs-identifier hs-var">const</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048565"><span class="hs-identifier hs-var">k</span></a></span><span class="annot"><span class="annottext">a -&gt; [a] -&gt; [a]
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">k
</span><a href="#local-6989586621681048564"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048565"><span class="hs-identifier hs-var">k</span></a></span><span class="hs-special">]</span><span> </span><span class="annot"><span class="annottext">Map k [a]
</span><a href="#local-6989586621681048566"><span class="hs-identifier hs-var">m</span></a></span><span>
</span><span id="line-291"></span><span>        </span><span class="hs-comment">-- Copy ticks and scopes into the given block</span><span>
</span><span id="line-292"></span><span>        </span><span id="local-6989586621681048575"><span class="annot"><span class="annottext">copyTo :: CmmBlock -&gt; CmmBlock
</span><a href="#local-6989586621681048575"><span class="hs-identifier hs-var hs-var">copyTo</span></a></span></span><span> </span><span id="local-6989586621681048561"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048561"><span class="hs-identifier hs-var">block</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; Map BlockId Key -&gt; Maybe Key
forall k a. Ord k =&gt; k -&gt; Map k a -&gt; Maybe a
</span><a href="../../containers/src/Data.Map.Internal.html#lookup"><span class="hs-identifier hs-var">M.lookup</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmBlock -&gt; BlockId
forall (thing :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
NonLocal thing =&gt;
thing C x -&gt; BlockId
</span><a href="GHC.Cmm.Dataflow.Graph.html#entryLabel"><span class="hs-identifier hs-var">entryLabel</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048561"><span class="hs-identifier hs-var">block</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Map BlockId Key
</span><a href="#local-6989586621681048572"><span class="hs-identifier hs-var">revEnv</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-293"></span><span>          </span><span class="annot"><span class="annottext">Maybe Key
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048561"><span class="hs-identifier hs-var">block</span></a></span><span>
</span><span id="line-294"></span><span>          </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621681048559"><span class="annot"><span class="annottext">Key
</span><a href="#local-6989586621681048559"><span class="hs-identifier hs-var">ls</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">(CmmBlock -&gt; CmmBlock -&gt; CmmBlock)
-&gt; CmmBlock -&gt; DistinctBlocks -&gt; CmmBlock
forall (t :: * -&gt; *) a b.
Foldable t =&gt;
(a -&gt; b -&gt; b) -&gt; b -&gt; t a -&gt; b
</span><a href="../../base/src/Data.Foldable.html#foldr"><span class="hs-identifier hs-var">foldr</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; CmmBlock -&gt; CmmBlock
forall {x :: Extensibility}.
CmmBlock -&gt; Block CmmNode C x -&gt; Block CmmNode C x
</span><a href="#local-6989586621681048557"><span class="hs-identifier hs-var">copy</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048561"><span class="hs-identifier hs-var">block</span></a></span><span> </span><span class="annot"><span class="annottext">(DistinctBlocks -&gt; CmmBlock) -&gt; DistinctBlocks -&gt; CmmBlock
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">(BlockId -&gt; Maybe CmmBlock) -&gt; Key -&gt; DistinctBlocks
forall a b. (a -&gt; Maybe b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/Data.Maybe.html#mapMaybe"><span class="hs-identifier hs-var">mapMaybe</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(BlockId -&gt; LabelMap CmmBlock -&gt; Maybe CmmBlock)
-&gt; LabelMap CmmBlock -&gt; BlockId -&gt; Maybe CmmBlock
forall a b c. (a -&gt; b -&gt; c) -&gt; b -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#flip"><span class="hs-identifier hs-var">flip</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; LabelMap CmmBlock -&gt; Maybe CmmBlock
forall (map :: * -&gt; *) a.
IsMap map =&gt;
KeyOf map -&gt; map a -&gt; Maybe a
</span><a href="GHC.Cmm.Dataflow.Collections.html#mapLookup"><span class="hs-identifier hs-var">mapLookup</span></a></span><span> </span><span class="annot"><span class="annottext">LabelMap CmmBlock
</span><a href="#local-6989586621681048574"><span class="hs-identifier hs-var">blockMap</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Key
</span><a href="#local-6989586621681048559"><span class="hs-identifier hs-var">ls</span></a></span><span>
</span><span id="line-295"></span><span>        </span><span id="local-6989586621681048557"><span class="annot"><span class="annottext">copy :: CmmBlock -&gt; Block CmmNode C x -&gt; Block CmmNode C x
</span><a href="#local-6989586621681048557"><span class="hs-identifier hs-var hs-var">copy</span></a></span></span><span> </span><span id="local-6989586621681048554"><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048554"><span class="hs-identifier hs-var">from</span></a></span></span><span> </span><span id="local-6989586621681048553"><span class="annot"><span class="annottext">Block CmmNode C x
</span><a href="#local-6989586621681048553"><span class="hs-identifier hs-var">to</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-296"></span><span>          </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621681048552"><span class="annot"><span class="annottext">ticks :: [CmmTickish]
</span><a href="#local-6989586621681048552"><span class="hs-identifier hs-var hs-var">ticks</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; [CmmTickish]
</span><a href="GHC.Cmm.Utils.html#blockTicks"><span class="hs-identifier hs-var">blockTicks</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048554"><span class="hs-identifier hs-var">from</span></a></span><span>
</span><span id="line-297"></span><span>              </span><span class="annot"><a href="GHC.Cmm.Node.html#CmmEntry"><span class="hs-identifier hs-type">CmmEntry</span></a></span><span>  </span><span class="annot"><span class="annottext">BlockId
</span><span class="hs-identifier">_</span></span><span>   </span><span id="local-6989586621681048547"><span class="annot"><span class="annottext">CmmTickScope
</span><a href="#local-6989586621681048547"><span class="hs-identifier hs-var">scp0</span></a></span></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">CmmBlock -&gt; CmmNode C O
forall (n :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
Block n C x -&gt; n C O
</span><a href="GHC.Cmm.Dataflow.Block.html#firstNode"><span class="hs-identifier hs-var">firstNode</span></a></span><span> </span><span class="annot"><span class="annottext">CmmBlock
</span><a href="#local-6989586621681048554"><span class="hs-identifier hs-var">from</span></a></span><span>
</span><span id="line-298"></span><span>              </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.Node.html#CmmEntry"><span class="hs-identifier hs-type">CmmEntry</span></a></span><span> </span><span id="local-6989586621681048543"><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048543"><span class="hs-identifier hs-var">lbl</span></a></span></span><span> </span><span id="local-6989586621681048542"><span class="annot"><span class="annottext">CmmTickScope
</span><a href="#local-6989586621681048542"><span class="hs-identifier hs-var">scp1</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621681048541"><span class="annot"><span class="annottext">Block CmmNode O x
</span><a href="#local-6989586621681048541"><span class="hs-identifier hs-var">code</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Block CmmNode C x -&gt; (CmmNode C O, Block CmmNode O x)
forall (n :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
Block n C x -&gt; (n C O, Block n O x)
</span><a href="GHC.Cmm.Dataflow.Block.html#blockSplitHead"><span class="hs-identifier hs-var">blockSplitHead</span></a></span><span> </span><span class="annot"><span class="annottext">Block CmmNode C x
</span><a href="#local-6989586621681048553"><span class="hs-identifier hs-var">to</span></a></span><span>
</span><span id="line-299"></span><span>          </span><span class="hs-keyword">in</span><span> </span><span class="annot"><span class="annottext">BlockId -&gt; CmmTickScope -&gt; CmmNode C O
</span><a href="GHC.Cmm.Node.html#CmmEntry"><span class="hs-identifier hs-var">CmmEntry</span></a></span><span> </span><span class="annot"><span class="annottext">BlockId
</span><a href="#local-6989586621681048543"><span class="hs-identifier hs-var">lbl</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">CmmTickScope -&gt; CmmTickScope -&gt; CmmTickScope
</span><a href="GHC.Cmm.Node.html#combineTickScopes"><span class="hs-identifier hs-var">combineTickScopes</span></a></span><span> </span><span class="annot"><span class="annottext">CmmTickScope
</span><a href="#local-6989586621681048547"><span class="hs-identifier hs-var">scp0</span></a></span><span> </span><span class="annot"><span class="annottext">CmmTickScope
</span><a href="#local-6989586621681048542"><span class="hs-identifier hs-var">scp1</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">CmmNode C O -&gt; Block CmmNode O x -&gt; Block CmmNode C x
forall (n :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
n C O -&gt; Block n O x -&gt; Block n C x
</span><a href="GHC.Cmm.Dataflow.Block.html#blockJoinHead"><span class="hs-operator hs-var">`blockJoinHead`</span></a></span><span>
</span><span id="line-300"></span><span>             </span><span class="annot"><span class="annottext">(CmmNode O O -&gt; Block CmmNode O x -&gt; Block CmmNode O x)
-&gt; Block CmmNode O x -&gt; [CmmNode O O] -&gt; Block CmmNode O x
forall (t :: * -&gt; *) a b.
Foldable t =&gt;
(a -&gt; b -&gt; b) -&gt; b -&gt; t a -&gt; b
</span><a href="../../base/src/Data.Foldable.html#foldr"><span class="hs-identifier hs-var">foldr</span></a></span><span> </span><span class="annot"><span class="annottext">CmmNode O O -&gt; Block CmmNode O x -&gt; Block CmmNode O x
forall (n :: Extensibility -&gt; Extensibility -&gt; *)
       (x :: Extensibility).
n O O -&gt; Block n O x -&gt; Block n O x
</span><a href="GHC.Cmm.Dataflow.Block.html#blockCons"><span class="hs-identifier hs-var">blockCons</span></a></span><span> </span><span class="annot"><span class="annottext">Block CmmNode O x
</span><a href="#local-6989586621681048541"><span class="hs-identifier hs-var">code</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(CmmTickish -&gt; CmmNode O O) -&gt; [CmmTickish] -&gt; [CmmNode O O]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">CmmTickish -&gt; CmmNode O O
</span><a href="GHC.Cmm.Node.html#CmmTick"><span class="hs-identifier hs-var">CmmTick</span></a></span><span> </span><span class="annot"><span class="annottext">[CmmTickish]
</span><a href="#local-6989586621681048552"><span class="hs-identifier hs-var">ticks</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-301"></span><span>
</span><span id="line-302"></span><span class="hs-comment">-- Group by [Label]</span><span>
</span><span id="line-303"></span><span class="hs-comment">-- See Note [Compressed TrieMap] in GHC.Core.Map about the usage of GenMap.</span><span>
</span><span id="line-304"></span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#groupByLabel"><span class="hs-identifier hs-type">groupByLabel</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span class="hs-special">]</span><span>
</span><span id="line-305"></span><span id="groupByLabel"><span class="annot"><span class="annottext">groupByLabel :: [(Key, DistinctBlocks)] -&gt; [(Key, [DistinctBlocks])]
</span><a href="GHC.Cmm.CommonBlockElim.html#groupByLabel"><span class="hs-identifier hs-var hs-var">groupByLabel</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-306"></span><span>  </span><span class="annot"><span class="annottext">ListMap
  (GenMap LabelMap)
  (Key (ListMap (GenMap LabelMap)), [DistinctBlocks])
-&gt; [(Key (ListMap (GenMap LabelMap)), DistinctBlocks)]
-&gt; [(Key (ListMap (GenMap LabelMap)), [DistinctBlocks])]
forall {m :: * -&gt; *} {a}.
TrieMap m =&gt;
m (Key m, [a]) -&gt; [(Key m, a)] -&gt; [(Key m, [a])]
</span><a href="#local-6989586621681048536"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ListMap (GenMap LabelMap) (Key, [DistinctBlocks])
forall (m :: * -&gt; *) a. TrieMap m =&gt; m a
</span><a href="GHC.Data.TrieMap.html#emptyTM"><span class="hs-identifier hs-var">TM.emptyTM</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Data.TrieMap.html#ListMap"><span class="hs-identifier hs-type">TM.ListMap</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Data.TrieMap.html#GenMap"><span class="hs-identifier hs-type">TM.GenMap</span></a></span><span> </span><span class="annot"><a href="GHC.Cmm.Dataflow.Label.html#LabelMap"><span class="hs-identifier hs-type">LabelMap</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#Key"><span class="hs-identifier hs-type">Key</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#DistinctBlocks"><span class="hs-identifier hs-type">DistinctBlocks</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-307"></span><span>    </span><span class="hs-keyword">where</span><span>
</span><span id="line-308"></span><span>      </span><span id="local-6989586621681048536"><span class="annot"><span class="annottext">go :: m (Key m, [a]) -&gt; [(Key m, a)] -&gt; [(Key m, [a])]
</span><a href="#local-6989586621681048536"><span class="hs-identifier hs-var hs-var">go</span></a></span></span><span> </span><span class="hs-glyph">!</span><span id="local-6989586621681048531"><span class="annot"><span class="annottext">m (Key m, [a])
</span><a href="#local-6989586621681048531"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">((Key m, [a]) -&gt; [(Key m, [a])] -&gt; [(Key m, [a])])
-&gt; m (Key m, [a]) -&gt; [(Key m, [a])] -&gt; [(Key m, [a])]
forall (m :: * -&gt; *) a b.
TrieMap m =&gt;
(a -&gt; b -&gt; b) -&gt; m a -&gt; b -&gt; b
</span><a href="GHC.Data.TrieMap.html#foldTM"><span class="hs-identifier hs-var">TM.foldTM</span></a></span><span> </span><span class="hs-special">(</span><span class="hs-glyph">:</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">m (Key m, [a])
</span><a href="#local-6989586621681048531"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span>
</span><span id="line-309"></span><span>      </span><span class="annot"><a href="#local-6989586621681048536"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="hs-glyph">!</span><span id="local-6989586621681048529"><span class="annot"><span class="annottext">m (Key m, [a])
</span><a href="#local-6989586621681048529"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span class="hs-special">(</span><span class="hs-special">(</span><span id="local-6989586621681048528"><span class="annot"><span class="annottext">Key m
</span><a href="#local-6989586621681048528"><span class="hs-identifier hs-var">k</span></a></span></span><span class="hs-special">,</span><span id="local-6989586621681048527"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048527"><span class="hs-identifier hs-var">v</span></a></span></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="hs-glyph hs-type">:</span></span><span> </span><span id="local-6989586621681048526"><span class="annot"><span class="annottext">[(Key m, a)]
</span><a href="#local-6989586621681048526"><span class="hs-identifier hs-var">entries</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">m (Key m, [a]) -&gt; [(Key m, a)] -&gt; [(Key m, [a])]
</span><a href="#local-6989586621681048536"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Key m -&gt; XT (Key m, [a]) -&gt; m (Key m, [a]) -&gt; m (Key m, [a])
forall (m :: * -&gt; *) b. TrieMap m =&gt; Key m -&gt; XT b -&gt; m b -&gt; m b
</span><a href="GHC.Data.TrieMap.html#alterTM"><span class="hs-identifier hs-var">TM.alterTM</span></a></span><span> </span><span class="annot"><span class="annottext">Key m
</span><a href="#local-6989586621681048528"><span class="hs-identifier hs-var">k</span></a></span><span> </span><span class="annot"><span class="annottext">XT (Key m, [a])
</span><a href="#local-6989586621681048524"><span class="hs-identifier hs-var">adjust</span></a></span><span> </span><span class="annot"><span class="annottext">m (Key m, [a])
</span><a href="#local-6989586621681048529"><span class="hs-identifier hs-var">m</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[(Key m, a)]
</span><a href="#local-6989586621681048526"><span class="hs-identifier hs-var">entries</span></a></span><span>
</span><span id="line-310"></span><span>        </span><span class="hs-keyword">where</span><span> </span><span class="hs-comment">--k' = map (getKey . getUnique) k</span><span>
</span><span id="line-311"></span><span>              </span><span id="local-6989586621681048524"><span class="annot"><span class="annottext">adjust :: XT (Key m, [a])
</span><a href="#local-6989586621681048524"><span class="hs-identifier hs-var hs-var">adjust</span></a></span></span><span> </span><span class="annot"><span class="annottext">Maybe (Key m, [a])
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Key m, [a]) -&gt; Maybe (Key m, [a])
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Key m
</span><a href="#local-6989586621681048528"><span class="hs-identifier hs-var">k</span></a></span><span class="hs-special">,</span><span class="hs-special">[</span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048527"><span class="hs-identifier hs-var">v</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span>
</span><span id="line-312"></span><span>              </span><span class="annot"><a href="#local-6989586621681048524"><span class="hs-identifier hs-var">adjust</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Key m
</span><span class="hs-identifier">_</span></span><span class="hs-special">,</span><span id="local-6989586621681048523"><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681048523"><span class="hs-identifier hs-var">vs</span></a></span></span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Key m, [a]) -&gt; Maybe (Key m, [a])
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Key m
</span><a href="#local-6989586621681048528"><span class="hs-identifier hs-var">k</span></a></span><span class="hs-special">,</span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048527"><span class="hs-identifier hs-var">v</span></a></span><span class="annot"><span class="annottext">a -&gt; [a] -&gt; [a]
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681048523"><span class="hs-identifier hs-var">vs</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-313"></span><span>
</span><span id="line-314"></span><span id="local-6989586621681049176"><span class="annot"><a href="GHC.Cmm.CommonBlockElim.html#groupByInt"><span class="hs-identifier hs-type">groupByInt</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621681049176"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621681049176"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621681049176"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span><span class="hs-special">]</span></span><span>
</span><span id="line-315"></span><span id="groupByInt"><span class="annot"><span class="annottext">groupByInt :: forall a. (a -&gt; Int) -&gt; [a] -&gt; [[a]]
</span><a href="GHC.Cmm.CommonBlockElim.html#groupByInt"><span class="hs-identifier hs-var hs-var">groupByInt</span></a></span></span><span> </span><span id="local-6989586621681048519"><span class="annot"><span class="annottext">a -&gt; Int
</span><a href="#local-6989586621681048519"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621681048518"><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681048518"><span class="hs-identifier hs-var">xs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqFM Int [a] -&gt; [[a]]
forall key elt. UniqFM key elt -&gt; [elt]
</span><a href="GHC.Types.Unique.FM.html#nonDetEltsUFM"><span class="hs-identifier hs-var">nonDetEltsUFM</span></a></span><span> </span><span class="annot"><span class="annottext">(UniqFM Int [a] -&gt; [[a]]) -&gt; UniqFM Int [a] -&gt; [[a]]
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">(UniqFM Int [a] -&gt; a -&gt; UniqFM Int [a])
-&gt; UniqFM Int [a] -&gt; [a] -&gt; UniqFM Int [a]
forall (t :: * -&gt; *) b a.
Foldable t =&gt;
(b -&gt; a -&gt; b) -&gt; b -&gt; t a -&gt; b
</span><a href="../../base/src/Data.Foldable.html#foldl%27"><span class="hs-identifier hs-var">List.foldl'</span></a></span><span> </span><span class="annot"><span class="annottext">UniqFM Int [a] -&gt; a -&gt; UniqFM Int [a]
</span><a href="#local-6989586621681048516"><span class="hs-identifier hs-var">go</span></a></span><span> </span><span class="annot"><span class="annottext">UniqFM Int [a]
forall key elt. UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#emptyUFM"><span class="hs-identifier hs-var">emptyUFM</span></a></span><span> </span><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681048518"><span class="hs-identifier hs-var">xs</span></a></span><span>
</span><span id="line-316"></span><span>   </span><span class="hs-comment">-- See Note [Unique Determinism and code generation]</span><span>
</span><span id="line-317"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-318"></span><span>    </span><span id="local-6989586621681048516"><span class="annot"><span class="annottext">go :: UniqFM Int [a] -&gt; a -&gt; UniqFM Int [a]
</span><a href="#local-6989586621681048516"><span class="hs-identifier hs-var hs-var">go</span></a></span></span><span> </span><span id="local-6989586621681048514"><span class="annot"><span class="annottext">UniqFM Int [a]
</span><a href="#local-6989586621681048514"><span class="hs-identifier hs-var">m</span></a></span></span><span> </span><span id="local-6989586621681048513"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048513"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Maybe [a] -&gt; Maybe [a]) -&gt; UniqFM Int [a] -&gt; Int -&gt; UniqFM Int [a]
forall key elt.
Uniquable key =&gt;
(Maybe elt -&gt; Maybe elt) -&gt; UniqFM key elt -&gt; key -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#alterUFM"><span class="hs-identifier hs-var">alterUFM</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe [a] -&gt; Maybe [a]
</span><a href="#local-6989586621681048511"><span class="hs-identifier hs-var">addEntry</span></a></span><span> </span><span class="annot"><span class="annottext">UniqFM Int [a]
</span><a href="#local-6989586621681048514"><span class="hs-identifier hs-var">m</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">a -&gt; Int
</span><a href="#local-6989586621681048519"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048513"><span class="hs-identifier hs-var">x</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-319"></span><span>      </span><span class="hs-keyword">where</span><span>
</span><span id="line-320"></span><span>        </span><span id="local-6989586621681048511"><span class="annot"><span class="annottext">addEntry :: Maybe [a] -&gt; Maybe [a]
</span><a href="#local-6989586621681048511"><span class="hs-identifier hs-var hs-var">addEntry</span></a></span></span><span> </span><span id="local-6989586621681048510"><span class="annot"><span class="annottext">Maybe [a]
</span><a href="#local-6989586621681048510"><span class="hs-identifier hs-var">xs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[a] -&gt; Maybe [a]
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="annot"><span class="annottext">([a] -&gt; Maybe [a]) -&gt; [a] -&gt; Maybe [a]
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24%21"><span class="hs-operator hs-var">$!</span></a></span><span> </span><span class="annot"><span class="annottext">[a] -&gt; ([a] -&gt; [a]) -&gt; Maybe [a] -&gt; [a]
forall b a. b -&gt; (a -&gt; b) -&gt; Maybe a -&gt; b
</span><a href="../../base/src/Data.Maybe.html#maybe"><span class="hs-identifier hs-var">maybe</span></a></span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048513"><span class="hs-identifier hs-var">x</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681048513"><span class="hs-identifier hs-var">x</span></a></span><span class="annot"><span class="annottext">a -&gt; [a] -&gt; [a]
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Maybe [a]
</span><a href="#local-6989586621681048510"><span class="hs-identifier hs-var">xs</span></a></span><span>
</span><span id="line-321"></span></pre></body></html>